pangukitsappdev.api.prompt package¶
Submodules¶
pangukitsappdev.api.prompt.prompt_config module¶
- class pangukitsappdev.api.prompt.prompt_config.PromptConfig(_env_file: Optional[Union[str, PathLike, List[Union[str, PathLike]], Tuple[Union[str, PathLike], ...]]] = '<object object>', _env_file_encoding: Optional[str] = None, _env_nested_delimiter: Optional[str] = None, _secrets_dir: Optional[Union[str, PathLike]] = None, *, custom_prompt_path: Optional[str] = None, default_prompt_path: str = 'prompts/default/')¶
-
Prompt参数 Attributes:
custom_prompt_path: 用户自定义prompt路径,优先生效 default_prompt_path: 预制模板路径
- custom_prompt_path: Optional[str]¶
- default_prompt_path: str¶
- class pangukitsappdev.api.prompt.prompt_config.PromptTemplatesFileConfig(_env_file: Optional[Union[str, PathLike, List[Union[str, PathLike]], Tuple[Union[str, PathLike], ...]]] = '<object object>', _env_file_encoding: Optional[str] = None, _env_nested_delimiter: Optional[str] = None, _secrets_dir: Optional[Union[str, PathLike]] = None, *, documents_stuff: str = 'documents/stuff.pt', documents_refine_qa: str = 'documents/refine_qa.pt', documents_refine_combine: str = 'documents/refine_combine.pt', documents_mapreduce_map: str = 'documents/mapreduce_map.pt', documents_mapreduce_reduce: str = 'documents/mapreduce_reduce.pt', documents_summarize_stuff: str = 'documents/summarize_stuff.pt', documents_summarize_refine_qa: str = 'documents/summarize_refine_qa.pt', documents_summarize_refine_combine: str = 'documents/summarize_refine_combine.pt', documents_summarize_mapreduce_map: str = 'documents/summarize_mapreduce_map.pt', documents_summarize_mapreduce_reduce: str = 'documents/summarize_mapreduce_reduce.pt', memory_summary: str = 'memory/summary.pt', system_out_put_parser: str = 'system/out_put_parser.pt', agent_react: str = 'agent/react.pt', agent_react_pangu: str = 'agent/react_pangu.pt', agent_tool_desc: str = 'agent/tool_desc.pt', agent_tool_desc_pangu: str = 'agent/tool_desc_pangu.pt', agent_tool_json_schema: str = 'agent/tool_json_schema.pt', agent_tool_simple_schema: str = 'agent/tool_simple_schema.pt', agent_react_pangu_2: str = 'agent/react_pangu_2.pt', agent_tool_desc_pangu_2: str = 'agent/tool_desc_pangu_2.pt', agent_react_pangu_unify: str = 'agent/react_pangu_unify.pt', conversation_default: str = 'conversation/default.pt', skill_conversation_rewrite: str = 'skill/conversation_rewrite.pt', skill_agent_session_summary: str = 'skill/agent_session_summary.pt', question_long_answer: str = 'question/long_answer.jinja2', question_short_answer: str = 'question/short_answer.jinja2', question_qa_with_sources_stuff: str = 'question/qa_with_sources_stuff.jinja2', question_question_only: str = 'question/question_only.jinja2')¶
-
模板文件存放结构 Attributes:
documents_stuff: documents/stuff.pt documents_refine_qa: documents/refine_qa.pt documents_refine_combine: documents/refine_combine.pt documents_mapreduce_map: documents/mapreduce_map.pt documents_mapreduce_reduce: documents/mapreduce_reduce.pt documents_summarize_stuff: documents/summarize_stuff.pt documents_summarize_refine_qa: documents/summarize_refine_qa.pt documents_summarize_refine_combine: documents/summarize_refine_combine.pt documents_summarize_mapreduce_map: documents/summarize_mapreduce_map.pt documents_summarize_mapreduce_reduce: documents/summarize_mapreduce_reduce.pt memory_summary: memory/summary.pt system_out_put_parser: system/out_put_parser.pt agent_react: agent/react.pt agent_react_pangu: agent/react_pangu.pt agent_tool_desc: agent/tool_desc.pt agent_tool_desc_pangu: agent/tool_desc_pangu.pt agent_tool_json_schema: agent/tool_json_schema.pt agent_react_pangu_2: agent/react_pangu_2.pt agent_tool_desc_pangu_2: agent/tool_desc_pangu_2.pt agent_react_pangu_unify: agent/react_pangu_unify.pt conversation_default: conversation/default.pt skill_conversation_rewrite: skill/conversation_rewrite.pt skill_agent_session_summary: skill/agent_session_summary.pt question_long_answer: question/long_answer.jinja2 question_short_answer: question/short_answer.jinja2 question_qa_with_sources_stuff: question/qa_with_sources_stuff.jinja2 question_question_only: question/question_only.jinja2
- agent_react: str¶
- agent_react_pangu: str¶
- agent_react_pangu_2: str¶
- agent_react_pangu_unify: str¶
- agent_tool_desc: str¶
- agent_tool_desc_pangu: str¶
- agent_tool_desc_pangu_2: str¶
- agent_tool_json_schema: str¶
- agent_tool_simple_schema: str¶
- conversation_default: str¶
- documents_mapreduce_map: str¶
- documents_mapreduce_reduce: str¶
- documents_refine_combine: str¶
- documents_refine_qa: str¶
- documents_stuff: str¶
- documents_summarize_mapreduce_map: str¶
- documents_summarize_mapreduce_reduce: str¶
- documents_summarize_refine_combine: str¶
- documents_summarize_refine_qa: str¶
- documents_summarize_stuff: str¶
- memory_summary: str¶
- question_long_answer: str¶
- question_qa_with_sources_stuff: str¶
- question_question_only: str¶
- question_short_answer: str¶
- skill_agent_session_summary: str¶
- skill_conversation_rewrite: str¶
- system_out_put_parser: str¶