Skip to content

tdfs4ds.agent

tdfs4ds.agent

tdfs4ds.agent -- the assistant (consumer agent, query optimizer, vector index, chat).

Everything here needs the agent packages (pip install tdfs4ds[agent]). The package is lazy: importing tdfs4ds.agent (or tdfs4ds itself) loads no language-model library; a name is resolved, and its module imported, on first use.

consumer_agent and query_optimizer are both submodule names and the names of the functions they define. The package attribute always resolves to the FUNCTION: a plain import of the submodule would store the module there, so the package is a module subclass that refuses to let a submodule replace those two names. Reach the module itself with importlib.import_module('tdfs4ds.agent.consumer_agent').

_EXPORTS module-attribute

_EXPORTS = {'query_optimizer': 'query_optimizer', 'aquery_optimizer': 'query_optimizer', 'skill_optimize_query': 'query_optimizer', 'skill_generate_candidates': 'query_optimizer', 'display_optimization_result': 'query_optimizer', 'skill_simplify_query': 'query_optimizer', 'simplify_query': 'query_optimizer', 'intent_classifier': 'consumer_agent', '_build_intent_model': 'consumer_agent', 'list_instruct_models': 'consumer_agent', 'get_data_domain': 'consumer_agent', 'detect_data_domain_for_object': 'consumer_agent', 'skill_search': 'consumer_agent', 'skill_definition': 'consumer_agent', 'skill_usage': 'consumer_agent', 'skill_freshness': 'consumer_agent', 'skill_summary': 'consumer_agent', 'skill_lineage': 'consumer_agent', 'skill_explain': 'consumer_agent', 'synthesize_answer': 'consumer_agent', 'IntentResult': 'consumer_agent', 'consumer_agent': 'graph', 'build_graph': 'graph', 'reset_consumer_agent': 'graph', 'get_embeddings': 'embedding', 'list_embedding_models': 'embedding', 'build_vector_index': 'vector_index', 'search_vector_index': 'vector_index', 'launch_chatbot': 'chatbot', 'launch_chatbot_with_index': 'chatbot', 'launch_chatbot_app': 'chatbot'}

_FUNCTION_SHADOWS module-attribute

_FUNCTION_SHADOWS = frozenset({'consumer_agent', 'query_optimizer'})

__all__ module-attribute

__all__ = list(_EXPORTS)

_AgentPackage

Bases: ModuleType

__setattr__

__setattr__(name, value)

__getattr__

__getattr__(name)

__dir__

__dir__()

Submodules