MCPcopy Create free account

hub / github.com/NanmiCoder/skills-agent-proto / functions

Functions280 in github.com/NanmiCoder/skills-agent-proto

↓ 1 callersFunctionformatToolCompact
(tool: ToolCallView)
web/src/components/ToolCallItem.tsx:13
↓ 1 callersFunctionformat_tool_result_compact
使用 Claude Code 风格格式化工具结果(树形输出) Args: name: 工具名称 content: 工具输出内容 max_lines: 最大显示行数 Returns: Rich 可渲染元素列表
src/langchain_skills/cli.py:274
↓ 1 callersMethodget_discovered_skills
(self)
src/langchain_skills/web_api.py:31
↓ 1 callersFunctionget_skill_content
便捷函数:获取 Skill 内容
src/langchain_skills/skill_loader.py:292
↓ 1 callersMethodget_system_prompt
(self)
src/langchain_skills/web_api.py:34
↓ 1 callersMethodget_system_prompt
获取当前 system prompt 用于演示和调试,展示 Level 1 注入的内容。
src/langchain_skills/agent.py:414
↓ 1 callersFunctioninferToolSuccess
(content: string, explicit?: boolean)
web/src/state/chatReducer.ts:164
↓ 1 callersFunctionlinesWithTreePrefix
(content: string, expanded: boolean)
web/src/components/ToolCallItem.tsx:48
↓ 1 callersFunctionloadSkills
()
web/src/App.tsx:53
↓ 1 callersFunctionmain
CLI 主入口
src/langchain_skills/cli.py:698
↓ 1 callersFunctionmain
主函数
examples/langchain_demo.py:260
↓ 1 callersFunctionmain
主入口
examples/basic_usage.py:199
↓ 1 callersFunctionmain
主入口
examples/interactive_chat.py:214
↓ 1 callersFunctionmain
主函数
examples/extract_article.py:98
↓ 1 callersFunctionnormalizeBaseUrl
(baseUrl: string)
web/src/lib/sse.ts:20
↓ 1 callersFunctionopenChatStream
({ apiBaseUrl, message, threadId, onEvent, onError, }: StreamOptions)
web/src/lib/sse.ts:24
↓ 1 callersFunctionphaseLabel
(phase: string)
web/src/components/ChatTimeline.tsx:13
↓ 1 callersFunctionprint_banner
打印欢迎横幅
src/langchain_skills/cli.py:468
↓ 1 callersFunctionprint_banner
打印欢迎横幅
examples/interactive_chat.py:39
↓ 1 callersFunctionpromptAsMarkdown
(prompt: string)
web/src/App.tsx:39
↓ 1 callersFunctionshowSpinner
(phase: string)
web/src/components/ChatTimeline.tsx:32
↓ 1 callersFunctionskillsAsMarkdown
(skills: SkillSummary[])
web/src/App.tsx:25
↓ 1 callersMethodstream_events
(self, message: str, thread_id: str = "default")
src/langchain_skills/web_api.py:37
↓ 1 callersFunctionupsertToolCall
( tools: ToolCallView[], event: ToolCallEvent, )
web/src/state/chatReducer.ts:189
FunctionApp
()
web/src/App.tsx:44
Method__init__
(self)
src/langchain_skills/cli.py:75
Method__init__
初始化 Agent Args: model: 模型名称,默认 claude-sonnet-4-5-20250929 model_provider: 模型提供商,支持 anthropic / openai
src/langchain_skills/agent.py:258
Method__init__
初始化加载器 Args: skill_paths: 自定义 Skills 搜索路径,默认为: - .claude/skills/ (项目级,优先) - ~/.claude/sk
src/langchain_skills/skill_loader.py:96
Method__init__
(self)
src/langchain_skills/stream/tracker.py:48
Method__init__
(self, working_directory: Path = None)
tests/test_tools.py:21
Function_default_agent_provider
Lazily initialize a single agent instance for API requests.
src/langchain_skills/web_api.py:62
Method_format_error
格式化错误输出
src/langchain_skills/stream/formatter.py:145
Method_format_json
格式化 JSON 输出
src/langchain_skills/stream/formatter.py:154
Method_format_markdown
格式化 Markdown 输出
src/langchain_skills/stream/formatter.py:172
Method_format_success
格式化成功输出
src/langchain_skills/stream/formatter.py:136
Method_handle_tool_use_block
处理 tool_use 块 - 立即发送 tool_call 事件 在收到 tool_use 时立即发送,让 CLI 可以显示"正在执行"状态。 避免重复发送(同一 tool 可能通过多个路径到达)。
src/langchain_skills/agent.py:648
Function_live_tests_enabled
()
tests/test_e2e_live.py:21
Functionbash
Execute a shell command (bash on Unix/macOS, cmd.exe on Windows). Use this for: - Running skill scripts (e.g., `uv run path/to/script.py
src/langchain_skills/tools.py:94
Functionchat_stream
( message: str = Query(..., min_length=1), thread_id: str = Query("default", min_length=1),
src/langchain_skills/web_api.py:106
FunctioncreateThread
()
web/src/App.tsx:187
Functioncreate_skills_agent
便捷函数:创建 Skills Agent Args: model: 模型名称 model_provider: 模型提供商 skill_paths: Skills 搜索路径 working_directory: 工作目
src/langchain_skills/agent.py:738
Functiondemo_without_thinking
演示不启用 thinking 的情况
examples/basic_usage.py:160
Methoddo_POST
(self)
tests/test_agent.py:20
Functionedit
Edit a file by replacing text. Use this to: - Modify existing code - Fix bugs by replacing incorrect code - Update configuration
src/langchain_skills/tools.py:348
Methodget_discovered_skills
(self)
tests/test_web_api.py:16
Functionget_prompt
()
src/langchain_skills/web_api.py:101
Functionget_status_symbol
获取状态符号,Windows cmd.exe 使用 ASCII 备选 在不支持 Unicode 的终端(如 Windows cmd.exe)上, 圆点符号可能显示为方框,因此提供 ASCII 备选方案。 Args: status: 工具状态
src/langchain_skills/stream/utils.py:26
Methodget_system_prompt
(self)
tests/test_web_api.py:25
Functionglob
Find files matching a glob pattern. Use this to: - Find files by name pattern (e.g., "**/*.py" for all Python files) - List files in
src/langchain_skills/tools.py:228
Functiongrep
Search for a pattern in files. Use this to: - Find code containing specific text or regex - Search for function/class definitions
src/langchain_skills/tools.py:272
FunctionhandleSend
(text: string)
web/src/App.tsx:107
Functionhealth
()
src/langchain_skills/web_api.py:89
Functionlist_dir
List contents of a directory. Use this to: - Explore directory structure - See what files exist in a folder - Check if files/fol
src/langchain_skills/tools.py:407
Functionlist_skills
()
src/langchain_skills/web_api.py:96
Functionload_skill
Load a skill's detailed instructions. This tool reads the SKILL.md file for the specified skill and returns its complete instructions. U
src/langchain_skills/tools.py:38
Methodlog_message
(self, format, *args)
tests/test_agent.py:75
Functionmain
Run development server for the Web API.
src/langchain_skills/web_api.py:148
Functionread_file
Read the contents of a file. Use this to: - Read skill documentation files - View script output files - Inspect any text file
src/langchain_skills/tools.py:160
Methodstream_events
(self, message: str, thread_id: str = "default")
tests/test_web_api.py:28
Methodtest_accumulate_text
测试文本内容累积
tests/test_cli.py:106
Methodtest_accumulate_thinking
测试 thinking 内容累积
tests/test_cli.py:98
Functiontest_anthropic_agent_keeps_thinking_kwargs
()
tests/test_agent.py:272
Methodtest_append_json_delta
测试累积 JSON 片段
tests/test_stream.py:155
Methodtest_append_json_delta_complex
测试复杂 JSON 片段累积
tests/test_stream.py:171
Methodtest_bash_command
(self)
tests/test_stream.py:360
Methodtest_bash_json_output
测试 bash JSON 输出
tests/test_tools.py:180
Methodtest_bash_long_command
(self)
tests/test_stream.py:364
Methodtest_bash_output_format_works_with_formatter
测试 bash 输出格式与 ToolResultFormatter 兼容
tests/test_tools.py:162
Methodtest_basic_output
(self)
tests/test_stream.py:421
Functiontest_chat_stream_endpoint_emits_sse_frames
()
tests/test_web_api.py:78
Functiontest_chat_stream_endpoint_wraps_errors_as_error_event
()
tests/test_web_api.py:92
Functiontest_chat_stream_frame_payload_is_valid_json
()
tests/test_web_api.py:110
Functiontest_chat_stream_requires_message
()
tests/test_web_api.py:102
Methodtest_clear
测试清空追踪器
tests/test_stream.py:148
Methodtest_command_no_output
测试无输出的命令
tests/test_tools.py:97
Methodtest_command_with_stderr
测试有 stderr 输出的命令
tests/test_tools.py:88
Methodtest_command_with_working_directory
测试工作目录
tests/test_tools.py:104
Methodtest_custom_indent
(self)
tests/test_stream.py:438
Methodtest_detect_error
(self)
tests/test_stream.py:250
Methodtest_detect_json
(self)
tests/test_stream.py:254
Methodtest_detect_json_with_ok_prefix
(self)
tests/test_stream.py:258
Methodtest_detect_markdown
(self)
tests/test_stream.py:262
Methodtest_detect_success
(self)
tests/test_stream.py:246
Methodtest_detect_text
(self)
tests/test_stream.py:266
Methodtest_display_limits
(self)
tests/test_stream.py:332
Methodtest_done_event
(self)
tests/test_stream.py:57
Methodtest_edit_file
(self)
tests/test_stream.py:384
Methodtest_emit_all_pending
测试发送所有待处理的工具调用
tests/test_stream.py:135
Methodtest_empty_args
(self)
tests/test_stream.py:404
Methodtest_empty_lines
(self)
tests/test_stream.py:434
Methodtest_empty_string
(self)
tests/test_stream.py:453
Methodtest_error_event
(self)
tests/test_stream.py:62
Methodtest_exact_limit
(self)
tests/test_stream.py:475
Methodtest_failed_command
测试失败的命令
tests/test_tools.py:81
Methodtest_failure_prefix
(self)
tests/test_stream.py:343
Methodtest_finalize_all_invalid_json
测试无效 JSON 不会覆盖原有 args
tests/test_stream.py:186
Methodtest_finalize_updates_args
测试 finalize 后参数更新 模拟流程: 1. 收到 tool_use(args 为空) 2. 收到 input_json_delta(累积参数) 3. finalize 后参数完整
tests/test_stream.py:214
Methodtest_format_returns_elements
(self)
tests/test_stream.py:283
Methodtest_format_tool_args
(self)
tests/test_cli.py:167
Methodtest_format_tool_args_truncate
(self)
tests/test_cli.py:171
← previousnext →101–200 of 280, ranked by callers