1---
2version: 2
3interactions:
4- id: 0
5 request:
6 proto: HTTP/1.1
7 proto_major: 1
8 proto_minor: 1
9 content_length: 819
10 host: ""
11 body: '{"messages":[{"content":"You will generate a short title based on the first message a user begins a conversation with.\n\n<rules>\n- Keep the title in the same language that the user wrote their message in.\n- Ensure it is not more than 50 characters long.\n- The title should be a summary of the user''s message.\n- It should be one line long.\n- Do not use quotes or colons.\n- The entire text you return will be used as the title.\n- Never return anything that is more than one sentence (one line) long.\n</rules>\n\n /no_think","role":"system"},{"content":"Generate a concise title for the following content:\n\nuse sourcegraph to search for ''func main'' in Go repositories\n <think>\n\n</think>","role":"user"}],"model":"gpt-oss-120b","max_completion_tokens":40,"stream_options":{"include_usage":true},"stream":true}'
12 headers:
13 Accept:
14 - application/json
15 Content-Type:
16 - application/json
17 User-Agent:
18 - Charm-Crush/devel (https://charm.land/crush)
19 url: https://hyper.charm.land/v1/chat/completions
20 method: POST
21 response:
22 proto: HTTP/2.0
23 proto_major: 2
24 proto_minor: 0
25 content_length: -1
26 uncompressed: true
27 body: |+
28 data: {"id":"chatcmpl-e6c46acec51f6245887eff57","object":"chat.completion.chunk","created":0,"model":"gpt-oss-120b","choices":[{"index":0,"delta":{"role":"assistant"},"finish_reason":null}]}
29
30 data: {"id":"chatcmpl-e6c46acec51f6245887eff57","object":"chat.completion.chunk","created":0,"model":"gpt-oss-120b","choices":[{"index":0,"delta":{"content":"Search"},"finish_reason":null}]}
31
32 data: {"id":"chatcmpl-e6c46acec51f6245887eff57","object":"chat.completion.chunk","created":0,"model":"gpt-oss-120b","choices":[{"index":0,"delta":{"content":" for"},"finish_reason":null}]}
33
34 data: {"id":"chatcmpl-e6c46acec51f6245887eff57","object":"chat.completion.chunk","created":0,"model":"gpt-oss-120b","choices":[{"index":0,"delta":{"content":" func"},"finish_reason":null}]}
35
36 data: {"id":"chatcmpl-e6c46acec51f6245887eff57","object":"chat.completion.chunk","created":0,"model":"gpt-oss-120b","choices":[{"index":0,"delta":{"content":" main"},"finish_reason":null}]}
37
38 data: {"id":"chatcmpl-e6c46acec51f6245887eff57","object":"chat.completion.chunk","created":0,"model":"gpt-oss-120b","choices":[{"index":0,"delta":{"content":" in"},"finish_reason":null}]}
39
40 data: {"id":"chatcmpl-e6c46acec51f6245887eff57","object":"chat.completion.chunk","created":0,"model":"gpt-oss-120b","choices":[{"index":0,"delta":{"content":" Go"},"finish_reason":null}]}
41
42 data: {"id":"chatcmpl-e6c46acec51f6245887eff57","object":"chat.completion.chunk","created":0,"model":"gpt-oss-120b","choices":[{"index":0,"delta":{"content":" repos"},"finish_reason":null}]}
43
44 data: {"id":"chatcmpl-e6c46acec51f6245887eff57","object":"chat.completion.chunk","created":0,"model":"gpt-oss-120b","choices":[{"index":0,"delta":{"content":" with"},"finish_reason":null}]}
45
46 data: {"id":"chatcmpl-e6c46acec51f6245887eff57","object":"chat.completion.chunk","created":0,"model":"gpt-oss-120b","choices":[{"index":0,"delta":{"content":" Source"},"finish_reason":null}]}
47
48 data: {"id":"chatcmpl-e6c46acec51f6245887eff57","object":"chat.completion.chunk","created":0,"model":"gpt-oss-120b","choices":[{"index":0,"delta":{"content":"graph"},"finish_reason":null}]}
49
50 data: {"id":"chatcmpl-e6c46acec51f6245887eff57","object":"chat.completion.chunk","created":0,"model":"gpt-oss-120b","choices":[{"index":0,"delta":{},"finish_reason":"stop"}],"usage":{"prompt_tokens":36,"completion_tokens":293,"total_tokens":505}}
51
52 data: [DONE]
53
54 headers:
55 Content-Type:
56 - text/event-stream
57 status: 200 OK
58 code: 200
59 duration: 3.248102625s
60- id: 1
61 request:
62 proto: HTTP/1.1
63 proto_major: 1
64 proto_minor: 1
65 content_length: 33234
66 host: ""
67 body: "{\"messages\":[{\"content\":\"You are Crush, a powerful AI Assistant that runs in the CLI.\\n\\n<critical_rules>\\nThese rules override everything else. Follow them strictly:\\n\\n1. **READ BEFORE EDITING**: Never edit a file you haven't already read in this conversation. Once read, you don't need to re-read unless it changed. Pay close attention to exact formatting, indentation, and whitespace - these must match exactly in your edits.\\n2. **BE AUTONOMOUS**: Don't ask questions - search, read, think, decide, act. Break complex tasks into steps and complete them all. Systematically try alternative strategies (different commands, search terms, tools, refactors, or scopes) until either the task is complete or you hit a hard external limit (missing credentials, permissions, files, or network access you cannot change). Only stop for actual blocking errors, not perceived difficulty.\\n3. **TEST AFTER CHANGES**: Run tests immediately after each modification.\\n4. **BE CONCISE**: Keep output concise (default <4 lines), unless explaining complex changes or asked for detail. Conciseness applies to output only, not to thoroughness of work.\\n5. **USE EXACT MATCHES**: When editing, match text exactly including whitespace, indentation, and line breaks.\\n6. **NEVER COMMIT**: Unless user explicitly says \\\"commit\\\". When committing, follow the `<git_commits>` format from the bash tool description exactly, including any configured attribution lines.\\n7. **FOLLOW MEMORY FILE INSTRUCTIONS**: If memory files contain specific instructions, preferences, or commands, you MUST follow them.\\n8. **NEVER ADD COMMENTS**: Only add comments if the user asked you to do so. Focus on *why* not *what*. NEVER communicate with the user through code comments.\\n9. **SECURITY FIRST**: Only assist with defensive security tasks. Refuse to create, modify, or improve code that may be used maliciously.\\n10. **NO URL GUESSING**: Only use URLs provided by the user or found in local files.\\n11. **NEVER PUSH TO REMOTE**: Don't push changes to remote repositories unless explicitly asked.\\n12. **DON'T REVERT CHANGES**: Don't revert changes unless they caused errors or the user explicitly asks.\\n13. **TOOL CONSTRAINTS**: Only use documented tools. Never attempt 'apply_patch' or 'apply_diff' - they don't exist. Use 'edit' or 'multiedit' instead.\\n14. **LOAD MATCHING SKILLS**: If any entry in `<available_skills>` matches the current task, you MUST call `view` on its `<location>` before taking any other action for that task. The `<description>` is only a trigger β the actual procedure, scripts, and references live in SKILL.md. Do NOT infer a skill's behavior from its description or skip loading it because you think you already know how to do the task.\\n</critical_rules>\\n\\n<communication_style>\\nKeep responses minimal:\\n- ALWAYS think and respond in the same spoken language the prompt was written in.\\n- Under 4 lines of text (tool use doesn't count)\\n- Conciseness is about **text only**: always fully implement the requested feature, tests, and wiring even if that requires many tool calls.\\n- No preamble (\\\"Here's...\\\", \\\"I'll...\\\")\\n- No postamble (\\\"Let me know...\\\", \\\"Hope this helps...\\\")\\n- One-word answers when possible\\n- No emojis ever\\n- No explanations unless user asks\\n- Never send acknowledgement-only responses; after receiving new context or instructions, immediately continue the task or state the concrete next action you will take.\\n- Use rich Markdown formatting (headings, bullet lists, tables, code fences) for any multi-sentence or explanatory answer; only use plain unformatted text if the user explicitly asks.\\n\\nExamples:\\nuser: what is 2+2?\\nassistant: 4\\n\\nuser: list files in src/\\nassistant: [uses ls tool]\\nfoo.c, bar.c, baz.c\\n\\nuser: which file has the foo implementation?\\nassistant: src/foo.c\\n\\nuser: add error handling to the login function\\nassistant: [searches for login, reads file, edits with exact match, runs tests]\\nDone\\n\\nuser: Where are errors from the client handled?\\nassistant: Clients are marked as failed in the `connectToServer` function in src/services/process.go:712.\\n</communication_style>\\n\\n<code_references>\\nWhen referencing specific functions or code locations, use the pattern `file_path:line_number` to help users navigate:\\n- Example: \\\"The error is handled in src/main.go:45\\\"\\n- Example: \\\"See the implementation in pkg/utils/helper.go:123-145\\\"\\n</code_references>\\n\\n<workflow>\\nFor every task, follow this sequence internally (don't narrate it):\\n\\n**Before acting**:\\n- Search codebase for relevant files\\n- Read files to understand current state\\n- Check memory for stored commands\\n- Identify what needs to change\\n- Use `git log` and `git blame` for additional context when needed\\n\\n**While acting**:\\n- Read entire file before editing it\\n- Before editing: verify exact whitespace and indentation from View output\\n- Use exact text for find/replace (include whitespace)\\n- Make one logical change at a time\\n- After each change: run tests\\n- If tests fail: fix immediately\\n- If edit fails: read more context, don't guess - the text must match exactly\\n- Keep going until query is completely resolved before yielding to user\\n- For longer tasks, send brief progress updates (under 10 words) BUT IMMEDIATELY CONTINUE WORKING - progress updates are not stopping points\\n\\n**Before finishing**:\\n- Verify ENTIRE query is resolved (not just first step)\\n- All described next steps must be completed\\n- Cross-check the original prompt and your own mental checklist; if any feasible part remains undone, continue working instead of responding.\\n- Run lint/typecheck if in memory\\n- Verify all changes work\\n- Keep response under 4 lines\\n\\n**Key behaviors**:\\n- Use find_references before changing shared code\\n- Follow existing patterns (check similar files)\\n- If stuck, try different approach (don't repeat failures)\\n- Make decisions yourself (search first, don't ask)\\n- Fix problems at root cause, not surface-level patches\\n- Don't fix unrelated bugs or broken tests (mention them in final message if relevant)\\n</workflow>\\n\\n<decision_making>\\n**Make decisions autonomously** - don't ask when you can:\\n- Search to find the answer\\n- Read files to see patterns\\n- Check similar code\\n- Infer from context\\n- Try most likely approach\\n- When requirements are underspecified but not obviously dangerous, make the most reasonable assumptions based on project patterns and memory files, briefly state them if needed, and proceed instead of waiting for clarification.\\n\\n**Only stop/ask user if**:\\n- Truly ambiguous business requirement\\n- Multiple valid approaches with big tradeoffs\\n- Could cause data loss\\n- Exhausted all attempts and hit actual blocking errors\\n\\n**When requesting information/access**:\\n- Exhaust all available tools, searches, and reasonable assumptions first.\\n- Never say \\\"Need more info\\\" without detail.\\n- In the same message, list each missing item, why it is required, acceptable substitutes, and what you already attempted.\\n- State exactly what you will do once the information arrives so the user knows the next step.\\n\\nWhen you must stop, first finish all unblocked parts of the request, then clearly report: (a) what you tried, (b) exactly why you are blocked, and (c) the minimal external action required. Don't stop just because one path failedβexhaust multiple plausible approaches first.\\n\\n**Never stop for**:\\n- Task seems too large (break it down)\\n- Multiple files to change (change them)\\n- Concerns about \\\"session limits\\\" (no such limits exist)\\n- Work will take many steps (do all the steps)\\n\\nExamples of autonomous decisions:\\n- File location β search for similar files\\n- Test command β check package.json/memory\\n- Code style β read existing code\\n- Library choice β check what's used\\n- Naming β follow existing names\\n</decision_making>\\n\\n<editing_files>\\n**Available edit tools:**\\n- `edit` - Single find/replace in a file\\n- `multiedit` - Multiple find/replace operations in one file\\n- `write` - Create/overwrite entire file\\n\\nNever use `apply_patch` or similar - those tools don't exist.\\n\\nCritical: ALWAYS read files before editing them in this conversation.\\n\\nWhen using edit tools:\\n1. Read the file first - note the EXACT indentation (spaces vs tabs, count)\\n2. Copy the exact text including ALL whitespace, newlines, and indentation\\n3. Include 3-5 lines of context before and after the target\\n4. Verify your old_string would appear exactly once in the file\\n5. If uncertain about whitespace, include more surrounding context\\n6. Verify edit succeeded\\n7. Run tests\\n\\n**Whitespace matters**:\\n- Count spaces/tabs carefully (use View tool line numbers as reference)\\n- Include blank lines if they exist\\n- Match line endings exactly\\n- When in doubt, include MORE context rather than less\\n\\nEfficiency tips:\\n- Don't re-read files after successful edits (tool will fail if it didn't work)\\n- Same applies for making folders, deleting files, etc.\\n\\nCommon mistakes to avoid:\\n- Editing without reading first\\n- Approximate text matches\\n- Wrong indentation (spaces vs tabs, wrong count)\\n- Missing or extra blank lines\\n- Not enough context (text appears multiple times)\\n- Trimming whitespace that exists in the original\\n- Not testing after changes\\n</editing_files>\\n\\n<whitespace_and_exact_matching>\\nThe Edit tool is extremely literal. \\\"Close enough\\\" will fail.\\n\\n**Before every edit**:\\n1. View the file and locate the exact lines to change\\n2. Copy the text EXACTLY including:\\n - Every space and tab\\n - Every blank line\\n - Opening/closing braces position\\n - Comment formatting\\n3. Include enough surrounding lines (3-5) to make it unique\\n4. Double-check indentation level matches\\n\\n**Common failures**:\\n- `func foo() {` vs `func foo(){` (space before brace)\\n- Tab vs 4 spaces vs 2 spaces\\n- Missing blank line before/after\\n- `// comment` vs `//comment` (space after //)\\n- Different number of spaces in indentation\\n\\n**If edit fails**:\\n- View the file again at the specific location\\n- Copy even more context\\n- Check for tabs vs spaces\\n- Verify line endings\\n- Try including the entire function/block if needed\\n- Never retry with guessed changes - get the exact text first\\n</whitespace_and_exact_matching>\\n\\n<task_completion>\\nEnsure every task is implemented completely, not partially or sketched.\\n\\n1. **Think before acting** (for non-trivial tasks)\\n - Identify all components that need changes (models, logic, routes, config, tests, docs)\\n - Consider edge cases and error paths upfront\\n - Form a mental checklist of requirements before making the first edit\\n - This planning happens internally - don't narrate it to the user\\n\\n2. **Implement end-to-end**\\n - Treat every request as complete work: if adding a feature, wire it fully\\n - Update all affected files (callers, configs, tests, docs)\\n - Don't leave TODOs or \\\"you'll also need to...\\\" - do it yourself\\n - No task is too large - break it down and complete all parts\\n - For multi-part prompts, treat each bullet/question as a checklist item and ensure every item is implemented or answered. Partial completion is not an acceptable final state.\\n\\n3. **Verify before finishing**\\n - Re-read the original request and verify each requirement is met\\n - Check for missing error handling, edge cases, or unwired code\\n - Run tests to confirm the implementation works\\n - Only say \\\"Done\\\" when truly done - never stop mid-task\\n</task_completion>\\n\\n<error_handling>\\nWhen errors occur:\\n1. Read complete error message\\n2. Understand root cause (isolate with debug logs or minimal reproduction if needed)\\n3. Try different approach (don't repeat same action)\\n4. Search for similar code that works\\n5. Make targeted fix\\n6. Test to verify\\n7. For each error, attempt at least two or three distinct remediation strategies (search similar code, adjust commands, narrow or widen scope, change approach) before concluding the problem is externally blocked.\\n\\nCommon errors:\\n- Import/Module β check paths, spelling, what exists\\n- Syntax β check brackets, indentation, typos\\n- Tests fail β read test, see what it expects\\n- File not found β use ls, check exact path\\n\\n**Edit tool \\\"old_string not found\\\"**:\\n- View the file again at the target location\\n- Copy the EXACT text including all whitespace\\n- Include more surrounding context (full function if needed)\\n- Check for tabs vs spaces, extra/missing blank lines\\n- Count indentation spaces carefully\\n- Don't retry with approximate matches - get the exact text\\n</error_handling>\\n\\n<memory_instructions>\\nMemory files store commands, preferences, and codebase info. Update them when you discover:\\n- Build/test/lint commands\\n- Code style preferences\\n- Important codebase patterns\\n- Useful project information\\n</memory_instructions>\\n\\n<code_conventions>\\nBefore writing code:\\n1. Check if library exists (look at imports, package.json)\\n2. Read similar code for patterns\\n3. Match existing style\\n4. Use same libraries/frameworks\\n5. Follow security best practices (never log secrets)\\n6. Don't use one-letter variable names unless requested\\n\\nNever assume libraries are available - verify first.\\n\\n**Ambition vs. precision**:\\n- New projects β be creative and ambitious with implementation\\n- Existing codebases β be surgical and precise, respect surrounding code\\n- Don't change filenames or variables unnecessarily\\n- Don't add formatters/linters/tests to codebases that don't have them\\n</code_conventions>\\n\\n<testing>\\nAfter significant changes:\\n- Start testing as specific as possible to code changed, then broaden to build confidence\\n- Use self-verification: write unit tests, add output logs, or use debug statements to verify your solutions\\n- Run relevant test suite\\n- If tests fail, fix before continuing\\n- Check memory for test commands\\n- Run lint/typecheck if available (on precise targets when possible)\\n- For formatters: iterate max 3 times to get it right; if still failing, present correct solution and note formatting issue\\n- Suggest adding commands to memory if not found\\n- Don't fix unrelated bugs or test failures (not your responsibility)\\n</testing>\\n\\n<tool_usage>\\n- Default to using tools (ls, grep, view, agent, tests, web_fetch, etc.) rather than speculation whenever they can reduce uncertainty or unlock progress, even if it takes multiple tool calls.\\n- Search before assuming\\n- Read files before editing\\n- Always use absolute paths for file operations (editing, reading, writing)\\n- Use Agent tool for complex searches\\n- Run tools in parallel when safe (no dependencies)\\n- When making multiple independent bash calls, send them in a single message with multiple tool calls for parallel execution\\n- Summarize tool output for user (they don't see it)\\n- Never use `curl` through the bash tool it is not allowed use the fetch tool instead.\\n- Only use the tools you know exist.\\n\\n<bash_commands>\\n**CRITICAL**: The `description` parameter is REQUIRED for all bash tool calls. Always provide it.\\n\\nWhen running non-trivial bash commands (especially those that modify the system):\\n- Briefly explain what the command does and why you're running it\\n- This ensures the user understands potentially dangerous operations\\n- Simple read-only commands (ls, cat, etc.) don't need explanation\\n- Use `&` for background processes that won't stop on their own (e.g., `node server.js &`)\\n- Avoid interactive commands - use non-interactive versions (e.g., `npm init -y` not `npm init`)\\n- Combine related commands to save time (e.g., `git status && git diff HEAD && git log -n 3`)\\n</bash_commands>\\n</tool_usage>\\n\\n<proactiveness>\\nBalance autonomy with user intent:\\n- When asked to do something β do it fully (including ALL follow-ups and \\\"next steps\\\")\\n- Never describe what you'll do next - just do it\\n- When the user provides new information or clarification, incorporate it immediately and keep executing instead of stopping with an acknowledgement.\\n- Responding with only a plan, outline, or TODO list (or any other purely verbal response) is failure; you must execute the plan via tools whenever execution is possible.\\n- When asked how to approach β explain first, don't auto-implement\\n- After completing work β stop, don't explain (unless asked)\\n- Don't surprise user with unexpected actions\\n</proactiveness>\\n\\n<final_answers>\\nAdapt verbosity to match the work completed:\\n\\n**Default (under 4 lines)**:\\n- Simple questions or single-file changes\\n- Casual conversation, greetings, acknowledgements\\n- One-word answers when possible\\n\\n**More detail allowed (up to 10-15 lines)**:\\n- Large multi-file changes that need walkthrough\\n- Complex refactoring where rationale adds value\\n- Tasks where understanding the approach is important\\n- When mentioning unrelated bugs/issues found\\n- Suggesting logical next steps user might want\\n- Structure longer answers with Markdown sections and lists, and put all code, commands, and config in fenced code blocks.\\n\\n**What to include in verbose answers**:\\n- Brief summary of what was done and why\\n- Key files/functions changed (with `file:line` references)\\n- Any important decisions or tradeoffs made\\n- Next steps or things user should verify\\n- Issues found but not fixed\\n\\n**What to avoid**:\\n- Don't show full file contents unless explicitly asked\\n- Don't explain how to save files or copy code (user has access to your work)\\n- Don't use \\\"Here's what I did\\\" or \\\"Let me know if...\\\" style preambles/postambles\\n- Keep tone direct and factual, like handing off work to a teammate\\n</final_answers>\\n\\n<env>\\nWorking directory: /tmp/crush-test/TestCoderAgent/glm-5.1/sourcegraph_tool\\nIs directory a git repo: no\\nPlatform: linux\\nToday's date: 1/1/2025\\n\\n</env>\\n\\n\\n\\n<available_skills>\\n <skill>\\n <name>jq</name>\\n <description>Use when the user needs to query, filter, reshape, extract, create, or construct JSON data β including API responses, config files, log output, or any structured data β or when helping the user write or debug JSON transformations.</description>\\n <location>crush://skills/jq/SKILL.md</location>\\n <type>builtin</type>\\n </skill>\\n</available_skills>\\n\\n<skills_usage>\\nThe `<description>` of each skill is a TRIGGER β it tells you *when* a skill applies. It is NOT a specification of what the skill does or how to do it. The procedure, scripts, commands, references, and required flags live only in the SKILL.md body. You do not know what a skill actually does until you have read its SKILL.md.\\n\\nMANDATORY activation flow:\\n1. Scan `<available_skills>` against the current user task.\\n2. If any skill's `<description>` matches, call the View tool with its `<location>` EXACTLY as shown β before any other tool call that performs the task.\\n3. Read the entire SKILL.md and follow its instructions.\\n4. Only then execute the task, using the skill's prescribed commands/tools.\\n\\nDo NOT skip step 2 because you think you already know how to do the task. Do NOT infer a skill's behavior from its name or description. If you find yourself about to run `bash`, `edit`, or any task-doing tool for a skill-eligible request without having just viewed the SKILL.md, stop and load the skill first.\\n\\nBuiltin skills (type=builtin) use virtual `crush://skills/...` location identifiers. The \\\"crush://\\\" prefix is NOT a URL, network address, or MCP resource β it is a special internal identifier the View tool understands natively. Pass the `<location>` verbatim to View.\\n\\nDo not use MCP tools (including read_mcp_resource) to load skills.\\nIf a skill mentions scripts, references, or assets, they live in the same folder as the skill itself (e.g., scripts/, references/, assets/ subdirectories within the skill's folder).\\n</skills_usage>\\n\\n\\n\\n\",\"role\":\"system\"},{\"content\":\"<system_reminder>This is a reminder that your todo list is currently empty. DO NOT mention this to the user explicitly because they are already aware.\\nIf you are working on tasks that would benefit from a todo list please use the \\\"todos\\\" tool to create one.\\nIf not, please feel free to ignore. Again do not mention this message to the user.</system_reminder>\",\"role\":\"user\"},{\"content\":\"use sourcegraph to search for 'func main' in Go repositories\",\"role\":\"user\"}],\"model\":\"glm-5.1\",\"max_tokens\":10000,\"stream_options\":{\"include_usage\":true},\"tool_choice\":\"auto\",\"tools\":[{\"function\":{\"name\":\"bash\",\"strict\":false,\"description\":\"Execute shell commands; long-running commands automatically move to background and return a shell ID.\\n\\n<cross_platform>\\nUses mvdan/sh interpreter (Bash-compatible on all platforms including Windows).\\nUse forward slashes for paths: \\\"ls C:/foo/bar\\\" not \\\"ls C:\\\\foo\\\\bar\\\".\\nCommon shell builtins and core utils available on Windows.\\n</cross_platform>\\n\\n<execution_steps>\\n1. Directory Verification: If creating directories/files, use LS tool to verify parent exists\\n2. Security Check: Banned commands (alias, aria2c, axel, chrome, curl, curlie, firefox, http-prompt, httpie, links, lynx, nc, safari, scp, ssh, telnet, w3m, wget, xh, doas, su, sudo, apk, apt, apt-cache, apt-get, dnf, dpkg, emerge, home-manager, makepkg, opkg, pacman, paru, pkg, pkg_add, pkg_delete, portage, rpm, yay, yum, zypper, at, batch, chkconfig, crontab, fdisk, mkfs, mount, parted, service, systemctl, umount, firewall-cmd, ifconfig, ip, iptables, netstat, pfctl, route, ufw) return error - explain to user. Safe read-only commands execute without prompts\\n3. Command Execution: Execute with proper quoting, capture output\\n4. Auto-Background: Commands exceeding 1 minute (default, configurable via `auto_background_after`) automatically move to background and return shell ID\\n5. Output Processing: Truncate if exceeds 30000 characters\\n6. Return Result: Include errors, metadata with <cwd></cwd> tags\\n</execution_steps>\\n\\n<usage_notes>\\n- Command required, working_dir optional (defaults to current directory)\\n- IMPORTANT: Use Grep/Glob/Agent tools instead of 'find'/'grep'. Use View/LS tools instead of 'cat'/'head'/'tail'/'ls'\\n- Chain with ';' or '&&', avoid newlines except in quoted strings\\n- Each command runs in independent shell (no state persistence between calls)\\n- Prefer absolute paths over 'cd' (use 'cd' only if user explicitly requests)\\n</usage_notes>\\n\\n<background_execution>\\n- Set run_in_background=true to run commands in a separate background shell\\n- Returns a shell ID for managing the background process\\n- Use job_output tool to view current output from background shell\\n- Use job_kill tool to terminate a background shell\\n- IMPORTANT: NEVER use `&` at the end of commands to run in background - use run_in_background parameter instead\\n- Commands that should run in background:\\n * Long-running servers (e.g., `npm start`, `python -m http.server`, `node server.js`)\\n * Watch/monitoring tasks (e.g., `npm run watch`, `tail -f logfile`)\\n * Continuous processes that don't exit on their own\\n * Any command expected to run indefinitely\\n- Commands that should NOT run in background:\\n * Build commands (e.g., `npm run build`, `go build`)\\n * Test suites (e.g., `npm test`, `pytest`)\\n * Git operations\\n * File operations\\n * Short-lived scripts\\n</background_execution>\\n\\n<git_commits>\\nWhen user asks to create git commit:\\n\\n1. Single message with three tool_use blocks (IMPORTANT for speed):\\n - git status (untracked files)\\n - git diff (staged/unstaged changes)\\n - git log (recent commit message style)\\n\\n2. Add relevant untracked files to staging. Don't commit files already modified at conversation start unless relevant.\\n\\n3. Analyze staged changes in <commit_analysis> tags:\\n - List changed/added files, summarize nature (feature/enhancement/bug fix/refactoring/test/docs)\\n - Brainstorm purpose/motivation, assess project impact, check for sensitive info\\n - Don't use tools beyond git context\\n - Draft concise (1-2 sentences) message focusing on \\\"why\\\" not \\\"what\\\"\\n - Use clear language, accurate reflection (\\\"add\\\"=new feature, \\\"update\\\"=enhancement, \\\"fix\\\"=bug fix)\\n - Avoid generic messages, review draft\\n\\n4. Create commit with attribution using HEREDOC:\\n git commit -m \\\"$(cat <<'EOF'\\n Commit message here.\\n\\n\\n \U0001F498 Generated with Crush\\n\\n\\n\\n Co-Authored-By: Crush <crush@charm.land>\\n\\n\\n EOF\\n )\\\"\\n\\n5. If pre-commit hook fails, retry ONCE. If fails again, hook preventing commit. If succeeds but files modified, MUST amend.\\n\\n6. Run git status to verify.\\n\\nNotes: Use \\\"git commit -am\\\" when possible, don't stage unrelated files, NEVER update config, don't push, no -i flags, no empty commits, return empty response.\\n</git_commits>\\n\\n<pull_requests>\\nUse gh command for ALL GitHub tasks. When user asks to create PR:\\n\\n1. Single message with multiple tool_use blocks (VERY IMPORTANT for speed):\\n - git status (untracked files)\\n - git diff (staged/unstaged changes)\\n - Check if branch tracks remote and is up to date\\n - git log and 'git diff main...HEAD' (full commit history from main divergence)\\n\\n2. Create new branch if needed\\n3. Commit changes if needed\\n4. Push to remote with -u flag if needed\\n\\n5. Analyze changes in <pr_analysis> tags:\\n - List commits since diverging from main\\n - Summarize nature of changes\\n - Brainstorm purpose/motivation\\n - Assess project impact\\n - Don't use tools beyond git context\\n - Check for sensitive information\\n - Draft concise (1-2 bullet points) PR summary focusing on \\\"why\\\"\\n - Ensure summary reflects ALL changes since main divergence\\n - Clear, concise language\\n - Accurate reflection of changes and purpose\\n - Avoid generic summaries\\n - Review draft\\n\\n6. Create PR with gh pr create using HEREDOC:\\n gh pr create --title \\\"title\\\" --body \\\"$(cat <<'EOF'\\n\\n ## Summary\\n\\n <1-3 bullet points>\\n\\n ## Test plan\\n\\n [Checklist of TODOs...]\\n\\n\\n \U0001F498 Generated with Crush\\n\\n\\n EOF\\n )\\\"\\n\\nImportant:\\n\\n- Return empty response - user sees gh output\\n- Never update git config\\n</pull_requests>\\n\\n<examples>\\nGood: pytest /foo/bar/tests\\nBad: cd /foo/bar && pytest tests\\n</examples>\\n\",\"parameters\":{\"properties\":{\"auto_background_after\":{\"description\":\"Seconds to wait before automatically moving the command to a background job (default: 60)\",\"type\":\"integer\"},\"command\":{\"description\":\"The command to execute\",\"type\":\"string\"},\"description\":{\"description\":\"A brief description of what the command does, try to keep it under 30 characters or so\",\"type\":\"string\"},\"run_in_background\":{\"description\":\"Set to true (boolean) to run this command in the background. Use job_output to read the output later.\",\"type\":\"boolean\"},\"working_dir\":{\"description\":\"The working directory to execute the command in (defaults to current directory)\",\"type\":\"string\"}},\"required\":[\"description\",\"command\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"download\",\"strict\":false,\"description\":\"Download a URL directly to a local file (binary-safe, streaming, max 100MB); overwrites without warning. For reading content into context use fetch.\",\"parameters\":{\"properties\":{\"file_path\":{\"description\":\"The local file path where the downloaded content should be saved\",\"type\":\"string\"},\"timeout\":{\"description\":\"Optional timeout in seconds (max 600)\",\"type\":\"integer\"},\"url\":{\"description\":\"The URL to download from\",\"type\":\"string\"}},\"required\":[\"url\",\"file_path\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"edit\",\"strict\":false,\"description\":\"Edit a file by exact find-and-replace; can also create or delete content. For renames/moves use bash. For large edits use write.\",\"parameters\":{\"properties\":{\"file_path\":{\"description\":\"The absolute path to the file to modify\",\"type\":\"string\"},\"new_string\":{\"description\":\"The text to replace it with\",\"type\":\"string\"},\"old_string\":{\"description\":\"The text to replace\",\"type\":\"string\"},\"replace_all\":{\"description\":\"Replace all occurrences of old_string (default false)\",\"type\":\"boolean\"}},\"required\":[\"file_path\",\"old_string\",\"new_string\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"multiedit\",\"strict\":false,\"description\":\"Apply multiple find-and-replace edits to a single file in one operation; edits run sequentially. Prefer over edit for multiple changes to the same file. Same exact-match rules as edit apply.\",\"parameters\":{\"properties\":{\"edits\":{\"description\":\"Array of edit operations to perform sequentially on the file\",\"items\":{\"properties\":{\"new_string\":{\"description\":\"The text to replace it with\",\"type\":\"string\"},\"old_string\":{\"description\":\"The text to replace\",\"type\":\"string\"},\"replace_all\":{\"description\":\"Replace all occurrences of old_string (default false).\",\"type\":\"boolean\"}},\"required\":[\"old_string\",\"new_string\"],\"type\":\"object\"},\"type\":\"array\"},\"file_path\":{\"description\":\"The absolute path to the file to modify\",\"type\":\"string\"}},\"required\":[\"file_path\",\"edits\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"fetch\",\"strict\":false,\"description\":\"Fetch raw content from a URL as text, markdown, or html (max 5MB); no AI processing. For analysis or extraction use agentic_fetch.\",\"parameters\":{\"properties\":{\"format\":{\"description\":\"The format to return the content in (text, markdown, or html)\",\"type\":\"string\"},\"timeout\":{\"description\":\"Optional timeout in seconds (max 120)\",\"type\":\"integer\"},\"url\":{\"description\":\"The URL to fetch content from\",\"type\":\"string\"}},\"required\":[\"url\",\"format\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"glob\",\"strict\":false,\"description\":\"Find files by name/pattern (glob syntax), sorted by modification time; max 100 results; skips hidden files. Use grep to search file contents.\",\"parameters\":{\"properties\":{\"path\":{\"description\":\"The directory to search in. Defaults to the current working directory.\",\"type\":\"string\"},\"pattern\":{\"description\":\"The glob pattern to match files against\",\"type\":\"string\"}},\"required\":[\"pattern\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"grep\",\"strict\":false,\"description\":\"Search file contents by regex or literal text; returns matching file paths sorted by modification time (max 100); respects .gitignore. Use glob to filter by filename, not contents.\",\"parameters\":{\"properties\":{\"include\":{\"description\":\"File pattern to include in the search (e.g. \\\"*.js\\\", \\\"*.{ts,tsx}\\\")\",\"type\":\"string\"},\"literal_text\":{\"description\":\"If true, the pattern will be treated as literal text with special regex characters escaped. Default is false.\",\"type\":\"boolean\"},\"path\":{\"description\":\"The directory to search in. Defaults to the current working directory.\",\"type\":\"string\"},\"pattern\":{\"description\":\"The regex pattern to search for in file contents\",\"type\":\"string\"}},\"required\":[\"pattern\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"ls\",\"strict\":false,\"description\":\"List files and directories as a tree; skips hidden files and common system dirs; max 1000 files. Use glob to find files by pattern, grep to search contents.\",\"parameters\":{\"properties\":{\"depth\":{\"description\":\"The maximum depth to traverse\",\"type\":\"integer\"},\"ignore\":{\"description\":\"List of glob patterns to ignore\",\"items\":{\"type\":\"string\"},\"type\":\"array\"},\"path\":{\"description\":\"The path to the directory to list (defaults to current working directory)\",\"type\":\"string\"}},\"required\":[],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"sourcegraph\",\"strict\":false,\"description\":\"Search code across public GitHub repositories via Sourcegraph; supports regex, language/repo/file filters, and symbol search (max 20 results). Only searches public repos.\",\"parameters\":{\"properties\":{\"context_window\":{\"description\":\"The context around the match to return (default: 10 lines)\",\"type\":\"integer\"},\"count\":{\"description\":\"Optional number of results to return (default: 10, max: 20)\",\"type\":\"integer\"},\"query\":{\"description\":\"The Sourcegraph search query\",\"type\":\"string\"},\"timeout\":{\"description\":\"Optional timeout in seconds (max 120)\",\"type\":\"integer\"}},\"required\":[\"query\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"view\",\"strict\":false,\"description\":\"Read a file by path with line numbers; supports offset and line limit (default 2000, max 5MB); renders images (PNG, JPEG, GIF, BMP, SVG, WebP); use ls for directories.\",\"parameters\":{\"properties\":{\"file_path\":{\"description\":\"The path to the file to read\",\"type\":\"string\"},\"limit\":{\"description\":\"The number of lines to read (defaults to 2000)\",\"type\":\"integer\"},\"offset\":{\"description\":\"The line number to start reading from (0-based)\",\"type\":\"integer\"}},\"required\":[\"file_path\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"write\",\"strict\":false,\"description\":\"Create or overwrite a file with given content; auto-creates parent dirs. Cannot append. Read the file first to avoid conflicts. For surgical changes use edit or multiedit.\",\"parameters\":{\"properties\":{\"content\":{\"description\":\"The content to write to the file\",\"type\":\"string\"},\"file_path\":{\"description\":\"The path to the file to write\",\"type\":\"string\"}},\"required\":[\"file_path\",\"content\"],\"type\":\"object\"}},\"type\":\"function\"}],\"stream\":true}"
68 headers:
69 Accept:
70 - application/json
71 Content-Type:
72 - application/json
73 User-Agent:
74 - Charm-Crush/devel (https://charm.land/crush)
75 url: https://hyper.charm.land/v1/chat/completions
76 method: POST
77 response:
78 proto: HTTP/2.0
79 proto_major: 2
80 proto_minor: 0
81 content_length: -1
82 uncompressed: true
83 body: |+
84 data: {"id":"chatcmpl-b120c6fa51c485694698c635","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"role":"assistant"},"finish_reason":null}]}
85
86 data: {"id":"chatcmpl-b120c6fa51c485694698c635","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"tool_calls":[{"id":"call_7b76","type":"function","index":0,"function":{"name":"sourcegraph","arguments":""}}]},"finish_reason":null}]}
87
88 data: {"id":"chatcmpl-b120c6fa51c485694698c635","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"tool_calls":[{"index":0,"function":{"arguments":"{\"count\": 10, \"query\": \"func main lang:go\"}"}}]},"finish_reason":null}]}
89
90 data: {"id":"chatcmpl-b120c6fa51c485694698c635","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{},"finish_reason":"tool_calls"}],"usage":{"prompt_tokens":607,"completion_tokens":39,"total_tokens":7686}}
91
92 data: [DONE]
93
94 headers:
95 Content-Type:
96 - text/event-stream
97 status: 200 OK
98 code: 200
99 duration: 5.162600875s
100- id: 2
101 request:
102 proto: HTTP/1.1
103 proto_major: 1
104 proto_minor: 1
105 content_length: 424
106 host: sourcegraph.com
107 body: '{"query":"query Search($query: String!) { search(query: $query, version: V2, patternType: keyword ) { results { matchCount, limitHit, resultCount, approximateResultCount, missing { name }, timedout { name }, indexUnavailable, results { __typename, ... on FileMatch { repository { name }, file { path, url, content }, lineMatches { preview, lineNumber, offsetAndLengths } } } } } }","variables":{"query":"func main lang:go"}}'
108 headers:
109 Content-Type:
110 - application/json
111 User-Agent:
112 - crush/1.0
113 url: https://sourcegraph.com/.api/graphql
114 method: POST
115 response:
116 proto: HTTP/2.0
117 proto_major: 2
118 proto_minor: 0
119 content_length: -1
120 uncompressed: true
121 body: '{"data":{"search":{"results":{"matchCount":30,"limitHit":true,"resultCount":30,"approximateResultCount":"30+","missing":[],"timedout":[],"indexUnavailable":false,"results":[{"__typename":"FileMatch","repository":{"name":"github.com/callicoder/golang-tutorials"},"file":{"path":"06-functions/01-function-declaration/main.go","url":"/r/github.com/callicoder/golang-tutorials/-/blob/06-functions/01-function-declaration/main.go","content":"package main\n\nimport \"fmt\"\n\nfunc avg(x float64, y float64) float64 {\n\treturn (x + y) / 2\n}\n\nfunc main() {\n\tx := 5.75\n\ty := 6.25\n\n\tresult := avg(x, y)\n\n\tfmt.Printf(\"Average of %.2f and %.2f = %.2f\\n\", x, y, result)\n}\n"},"lineMatches":[{"preview":"func main() {","lineNumber":8,"offsetAndLengths":[[0,9]]},{"preview":"package main","lineNumber":0,"offsetAndLengths":[[8,4]]},{"preview":"func avg(x float64, y float64) float64 {","lineNumber":4,"offsetAndLengths":[[0,4]]}]},{"__typename":"FileMatch","repository":{"name":"github.com/ondrajz/go-callvis"},"file":{"path":"examples/main/main.go","url":"/r/github.com/ondrajz/go-callvis/-/blob/examples/main/main.go","content":"package main\n\nimport (\n\t\"github.com/ofabry/go-callvis/examples/main/mypkg\"\n)\n\nfunc main() {\n\tfuncs()\n\tvar c calls\n\tc.execution()\n\tc.invocation()\n}\n\nfunc funcs() {\n\tmypkg.Exported()\n}\n\ntype calls struct{}\n\nfunc (calls) execution() {\n\tmypkg.Regular()\n}\n\nfunc (calls) invocation() {\n\tmypkg.T.Static()\n\tvar i mypkg.Iface = mypkg.T\n\ti.Dynamic()\n}\n"},"lineMatches":[{"preview":"func main() {","lineNumber":6,"offsetAndLengths":[[0,9]]},{"preview":"\tfuncs()","lineNumber":7,"offsetAndLengths":[[1,4]]},{"preview":"func funcs() {","lineNumber":13,"offsetAndLengths":[[0,4],[5,4]]},{"preview":"package main","lineNumber":0,"offsetAndLengths":[[8,4]]},{"preview":"func (calls) execution() {","lineNumber":19,"offsetAndLengths":[[0,4]]},{"preview":"func (calls) invocation() {","lineNumber":23,"offsetAndLengths":[[0,4]]},{"preview":"\t\"github.com/ofabry/go-callvis/examples/main/mypkg\"","lineNumber":3,"offsetAndLengths":[[40,4]]}]},{"__typename":"FileMatch","repository":{"name":"github.com/callicoder/golang-tutorials"},"file":{"path":"13-methods/02-methods-are-functions/main.go","url":"/r/github.com/callicoder/golang-tutorials/-/blob/13-methods/02-methods-are-functions/main.go","content":"package main\n\nimport (\n\t\"fmt\"\n)\n\n// Struct type - `Point`\ntype Point struct {\n\tX, Y float64\n}\n\nfunc IsAboveFunc(p Point, y float64) bool {\n\treturn p.Y \u003e y\n}\n\n/*\nCompare the above function with the corresponding method -\nfunc (p Point) IsAbove(y float64) bool {\n\treturn p.Y \u003e y\n}\n*/\n\nfunc main() {\n\tp := Point{2.5, -3.0}\n\n\tfmt.Println(\"Point : \", p)\n\n\tfmt.Println(\"Is Point p located above the line y = 1.0 ? : \", IsAboveFunc(p, 1))\n}\n"},"lineMatches":[{"preview":"func main() {","lineNumber":22,"offsetAndLengths":[[0,9]]},{"preview":"package main","lineNumber":0,"offsetAndLengths":[[8,4]]},{"preview":"func IsAboveFunc(p Point, y float64) bool {","lineNumber":11,"offsetAndLengths":[[0,4],[12,4]]},{"preview":"Compare the above function with the corresponding method -","lineNumber":16,"offsetAndLengths":[[18,4]]},{"preview":"func (p Point) IsAbove(y float64) bool {","lineNumber":17,"offsetAndLengths":[[0,4]]},{"preview":"\tfmt.Println(\"Is Point p located above the line y = 1.0 ? : \", IsAboveFunc(p, 1))","lineNumber":27,"offsetAndLengths":[[70,4]]}]},{"__typename":"FileMatch","repository":{"name":"github.com/agusrichard/go-workbook"},"file":{"path":"functional-programming/content-2/main.go","url":"/r/github.com/agusrichard/go-workbook/-/blob/functional-programming/content-2/main.go","content":"package main\n\nimport \"fmt\"\n\nfunc addition(x, y int) int {\n\treturn x + y\n}\n\nfunc curryAddition(x int) func(y int) int {\n\treturn func(y int) int {\n\t\treturn x + y\n\t}\n}\n\nfunc main() {\n\tfmt.Println(addition(1, 2))\n\n\tadd1 := curryAddition(1)\n\tadd10 := add1(10)\n\tfmt.Println(add10)\n}\n"},"lineMatches":[{"preview":"func main() {","lineNumber":14,"offsetAndLengths":[[0,9]]},{"preview":"package main","lineNumber":0,"offsetAndLengths":[[8,4]]},{"preview":"func curryAddition(x int) func(y int) int {","lineNumber":8,"offsetAndLengths":[[0,4],[26,4]]},{"preview":"\treturn func(y int) int {","lineNumber":9,"offsetAndLengths":[[8,4]]},{"preview":"func addition(x, y int) int {","lineNumber":4,"offsetAndLengths":[[0,4]]}]},{"__typename":"FileMatch","repository":{"name":"github.com/callicoder/golang-tutorials"},"file":{"path":"13-methods/07-method-with-value-receiver-vs-function-with-value-argument/main.go","url":"/r/github.com/callicoder/golang-tutorials/-/blob/13-methods/07-method-with-value-receiver-vs-function-with-value-argument/main.go","content":"package main\n\nimport (\n\t\"fmt\"\n)\n\n// Struct type - `Point`\ntype Point struct {\n\tX, Y float64\n}\n\nfunc (p Point) IsAbove(y float64) bool {\n\treturn p.Y \u003e y\n}\n\nfunc IsAboveFunc(p Point, y float64) bool {\n\treturn p.Y \u003e y\n}\n\nfunc main() {\n\tp := Point{0, 4}\n\tptr := \u0026p\n\n\tfmt.Println(\"Point p = \", p)\n\n\t// Calling a Method with Value receiver\n\tp.IsAbove(1) // Valid\n\tptr.IsAbove(1) // Valid\n\n\t// Calling a Function with a Value argument\n\tIsAboveFunc(p, 1) // Valid\n\t// IsAboveFunc(ptr, 1) // Not Valid\n}\n"},"lineMatches":[{"preview":"func main() {","lineNumber":19,"offsetAndLengths":[[0,9]]},{"preview":"package main","lineNumber":0,"offsetAndLengths":[[8,4]]},{"preview":"func IsAboveFunc(p Point, y float64) bool {","lineNumber":15,"offsetAndLengths":[[0,4],[12,4]]},{"preview":"\t// Calling a Function with a Value argument","lineNumber":29,"offsetAndLengths":[[14,4]]},{"preview":"\tIsAboveFunc(p, 1) // Valid","lineNumber":30,"offsetAndLengths":[[8,4]]}]}]}}}}'
122 headers:
123 Content-Type:
124 - application/json
125 status: 200 OK
126 code: 200
127 duration: 1.420517708s
128- id: 3
129 request:
130 proto: HTTP/1.1
131 proto_major: 1
132 proto_minor: 1
133 content_length: 43385
134 host: ""
135 body: "{\"messages\":[{\"content\":\"You are Crush, a powerful AI Assistant that runs in the CLI.\\n\\n<critical_rules>\\nThese rules override everything else. Follow them strictly:\\n\\n1. **READ BEFORE EDITING**: Never edit a file you haven't already read in this conversation. Once read, you don't need to re-read unless it changed. Pay close attention to exact formatting, indentation, and whitespace - these must match exactly in your edits.\\n2. **BE AUTONOMOUS**: Don't ask questions - search, read, think, decide, act. Break complex tasks into steps and complete them all. Systematically try alternative strategies (different commands, search terms, tools, refactors, or scopes) until either the task is complete or you hit a hard external limit (missing credentials, permissions, files, or network access you cannot change). Only stop for actual blocking errors, not perceived difficulty.\\n3. **TEST AFTER CHANGES**: Run tests immediately after each modification.\\n4. **BE CONCISE**: Keep output concise (default <4 lines), unless explaining complex changes or asked for detail. Conciseness applies to output only, not to thoroughness of work.\\n5. **USE EXACT MATCHES**: When editing, match text exactly including whitespace, indentation, and line breaks.\\n6. **NEVER COMMIT**: Unless user explicitly says \\\"commit\\\". When committing, follow the `<git_commits>` format from the bash tool description exactly, including any configured attribution lines.\\n7. **FOLLOW MEMORY FILE INSTRUCTIONS**: If memory files contain specific instructions, preferences, or commands, you MUST follow them.\\n8. **NEVER ADD COMMENTS**: Only add comments if the user asked you to do so. Focus on *why* not *what*. NEVER communicate with the user through code comments.\\n9. **SECURITY FIRST**: Only assist with defensive security tasks. Refuse to create, modify, or improve code that may be used maliciously.\\n10. **NO URL GUESSING**: Only use URLs provided by the user or found in local files.\\n11. **NEVER PUSH TO REMOTE**: Don't push changes to remote repositories unless explicitly asked.\\n12. **DON'T REVERT CHANGES**: Don't revert changes unless they caused errors or the user explicitly asks.\\n13. **TOOL CONSTRAINTS**: Only use documented tools. Never attempt 'apply_patch' or 'apply_diff' - they don't exist. Use 'edit' or 'multiedit' instead.\\n14. **LOAD MATCHING SKILLS**: If any entry in `<available_skills>` matches the current task, you MUST call `view` on its `<location>` before taking any other action for that task. The `<description>` is only a trigger β the actual procedure, scripts, and references live in SKILL.md. Do NOT infer a skill's behavior from its description or skip loading it because you think you already know how to do the task.\\n</critical_rules>\\n\\n<communication_style>\\nKeep responses minimal:\\n- ALWAYS think and respond in the same spoken language the prompt was written in.\\n- Under 4 lines of text (tool use doesn't count)\\n- Conciseness is about **text only**: always fully implement the requested feature, tests, and wiring even if that requires many tool calls.\\n- No preamble (\\\"Here's...\\\", \\\"I'll...\\\")\\n- No postamble (\\\"Let me know...\\\", \\\"Hope this helps...\\\")\\n- One-word answers when possible\\n- No emojis ever\\n- No explanations unless user asks\\n- Never send acknowledgement-only responses; after receiving new context or instructions, immediately continue the task or state the concrete next action you will take.\\n- Use rich Markdown formatting (headings, bullet lists, tables, code fences) for any multi-sentence or explanatory answer; only use plain unformatted text if the user explicitly asks.\\n\\nExamples:\\nuser: what is 2+2?\\nassistant: 4\\n\\nuser: list files in src/\\nassistant: [uses ls tool]\\nfoo.c, bar.c, baz.c\\n\\nuser: which file has the foo implementation?\\nassistant: src/foo.c\\n\\nuser: add error handling to the login function\\nassistant: [searches for login, reads file, edits with exact match, runs tests]\\nDone\\n\\nuser: Where are errors from the client handled?\\nassistant: Clients are marked as failed in the `connectToServer` function in src/services/process.go:712.\\n</communication_style>\\n\\n<code_references>\\nWhen referencing specific functions or code locations, use the pattern `file_path:line_number` to help users navigate:\\n- Example: \\\"The error is handled in src/main.go:45\\\"\\n- Example: \\\"See the implementation in pkg/utils/helper.go:123-145\\\"\\n</code_references>\\n\\n<workflow>\\nFor every task, follow this sequence internally (don't narrate it):\\n\\n**Before acting**:\\n- Search codebase for relevant files\\n- Read files to understand current state\\n- Check memory for stored commands\\n- Identify what needs to change\\n- Use `git log` and `git blame` for additional context when needed\\n\\n**While acting**:\\n- Read entire file before editing it\\n- Before editing: verify exact whitespace and indentation from View output\\n- Use exact text for find/replace (include whitespace)\\n- Make one logical change at a time\\n- After each change: run tests\\n- If tests fail: fix immediately\\n- If edit fails: read more context, don't guess - the text must match exactly\\n- Keep going until query is completely resolved before yielding to user\\n- For longer tasks, send brief progress updates (under 10 words) BUT IMMEDIATELY CONTINUE WORKING - progress updates are not stopping points\\n\\n**Before finishing**:\\n- Verify ENTIRE query is resolved (not just first step)\\n- All described next steps must be completed\\n- Cross-check the original prompt and your own mental checklist; if any feasible part remains undone, continue working instead of responding.\\n- Run lint/typecheck if in memory\\n- Verify all changes work\\n- Keep response under 4 lines\\n\\n**Key behaviors**:\\n- Use find_references before changing shared code\\n- Follow existing patterns (check similar files)\\n- If stuck, try different approach (don't repeat failures)\\n- Make decisions yourself (search first, don't ask)\\n- Fix problems at root cause, not surface-level patches\\n- Don't fix unrelated bugs or broken tests (mention them in final message if relevant)\\n</workflow>\\n\\n<decision_making>\\n**Make decisions autonomously** - don't ask when you can:\\n- Search to find the answer\\n- Read files to see patterns\\n- Check similar code\\n- Infer from context\\n- Try most likely approach\\n- When requirements are underspecified but not obviously dangerous, make the most reasonable assumptions based on project patterns and memory files, briefly state them if needed, and proceed instead of waiting for clarification.\\n\\n**Only stop/ask user if**:\\n- Truly ambiguous business requirement\\n- Multiple valid approaches with big tradeoffs\\n- Could cause data loss\\n- Exhausted all attempts and hit actual blocking errors\\n\\n**When requesting information/access**:\\n- Exhaust all available tools, searches, and reasonable assumptions first.\\n- Never say \\\"Need more info\\\" without detail.\\n- In the same message, list each missing item, why it is required, acceptable substitutes, and what you already attempted.\\n- State exactly what you will do once the information arrives so the user knows the next step.\\n\\nWhen you must stop, first finish all unblocked parts of the request, then clearly report: (a) what you tried, (b) exactly why you are blocked, and (c) the minimal external action required. Don't stop just because one path failedβexhaust multiple plausible approaches first.\\n\\n**Never stop for**:\\n- Task seems too large (break it down)\\n- Multiple files to change (change them)\\n- Concerns about \\\"session limits\\\" (no such limits exist)\\n- Work will take many steps (do all the steps)\\n\\nExamples of autonomous decisions:\\n- File location β search for similar files\\n- Test command β check package.json/memory\\n- Code style β read existing code\\n- Library choice β check what's used\\n- Naming β follow existing names\\n</decision_making>\\n\\n<editing_files>\\n**Available edit tools:**\\n- `edit` - Single find/replace in a file\\n- `multiedit` - Multiple find/replace operations in one file\\n- `write` - Create/overwrite entire file\\n\\nNever use `apply_patch` or similar - those tools don't exist.\\n\\nCritical: ALWAYS read files before editing them in this conversation.\\n\\nWhen using edit tools:\\n1. Read the file first - note the EXACT indentation (spaces vs tabs, count)\\n2. Copy the exact text including ALL whitespace, newlines, and indentation\\n3. Include 3-5 lines of context before and after the target\\n4. Verify your old_string would appear exactly once in the file\\n5. If uncertain about whitespace, include more surrounding context\\n6. Verify edit succeeded\\n7. Run tests\\n\\n**Whitespace matters**:\\n- Count spaces/tabs carefully (use View tool line numbers as reference)\\n- Include blank lines if they exist\\n- Match line endings exactly\\n- When in doubt, include MORE context rather than less\\n\\nEfficiency tips:\\n- Don't re-read files after successful edits (tool will fail if it didn't work)\\n- Same applies for making folders, deleting files, etc.\\n\\nCommon mistakes to avoid:\\n- Editing without reading first\\n- Approximate text matches\\n- Wrong indentation (spaces vs tabs, wrong count)\\n- Missing or extra blank lines\\n- Not enough context (text appears multiple times)\\n- Trimming whitespace that exists in the original\\n- Not testing after changes\\n</editing_files>\\n\\n<whitespace_and_exact_matching>\\nThe Edit tool is extremely literal. \\\"Close enough\\\" will fail.\\n\\n**Before every edit**:\\n1. View the file and locate the exact lines to change\\n2. Copy the text EXACTLY including:\\n - Every space and tab\\n - Every blank line\\n - Opening/closing braces position\\n - Comment formatting\\n3. Include enough surrounding lines (3-5) to make it unique\\n4. Double-check indentation level matches\\n\\n**Common failures**:\\n- `func foo() {` vs `func foo(){` (space before brace)\\n- Tab vs 4 spaces vs 2 spaces\\n- Missing blank line before/after\\n- `// comment` vs `//comment` (space after //)\\n- Different number of spaces in indentation\\n\\n**If edit fails**:\\n- View the file again at the specific location\\n- Copy even more context\\n- Check for tabs vs spaces\\n- Verify line endings\\n- Try including the entire function/block if needed\\n- Never retry with guessed changes - get the exact text first\\n</whitespace_and_exact_matching>\\n\\n<task_completion>\\nEnsure every task is implemented completely, not partially or sketched.\\n\\n1. **Think before acting** (for non-trivial tasks)\\n - Identify all components that need changes (models, logic, routes, config, tests, docs)\\n - Consider edge cases and error paths upfront\\n - Form a mental checklist of requirements before making the first edit\\n - This planning happens internally - don't narrate it to the user\\n\\n2. **Implement end-to-end**\\n - Treat every request as complete work: if adding a feature, wire it fully\\n - Update all affected files (callers, configs, tests, docs)\\n - Don't leave TODOs or \\\"you'll also need to...\\\" - do it yourself\\n - No task is too large - break it down and complete all parts\\n - For multi-part prompts, treat each bullet/question as a checklist item and ensure every item is implemented or answered. Partial completion is not an acceptable final state.\\n\\n3. **Verify before finishing**\\n - Re-read the original request and verify each requirement is met\\n - Check for missing error handling, edge cases, or unwired code\\n - Run tests to confirm the implementation works\\n - Only say \\\"Done\\\" when truly done - never stop mid-task\\n</task_completion>\\n\\n<error_handling>\\nWhen errors occur:\\n1. Read complete error message\\n2. Understand root cause (isolate with debug logs or minimal reproduction if needed)\\n3. Try different approach (don't repeat same action)\\n4. Search for similar code that works\\n5. Make targeted fix\\n6. Test to verify\\n7. For each error, attempt at least two or three distinct remediation strategies (search similar code, adjust commands, narrow or widen scope, change approach) before concluding the problem is externally blocked.\\n\\nCommon errors:\\n- Import/Module β check paths, spelling, what exists\\n- Syntax β check brackets, indentation, typos\\n- Tests fail β read test, see what it expects\\n- File not found β use ls, check exact path\\n\\n**Edit tool \\\"old_string not found\\\"**:\\n- View the file again at the target location\\n- Copy the EXACT text including all whitespace\\n- Include more surrounding context (full function if needed)\\n- Check for tabs vs spaces, extra/missing blank lines\\n- Count indentation spaces carefully\\n- Don't retry with approximate matches - get the exact text\\n</error_handling>\\n\\n<memory_instructions>\\nMemory files store commands, preferences, and codebase info. Update them when you discover:\\n- Build/test/lint commands\\n- Code style preferences\\n- Important codebase patterns\\n- Useful project information\\n</memory_instructions>\\n\\n<code_conventions>\\nBefore writing code:\\n1. Check if library exists (look at imports, package.json)\\n2. Read similar code for patterns\\n3. Match existing style\\n4. Use same libraries/frameworks\\n5. Follow security best practices (never log secrets)\\n6. Don't use one-letter variable names unless requested\\n\\nNever assume libraries are available - verify first.\\n\\n**Ambition vs. precision**:\\n- New projects β be creative and ambitious with implementation\\n- Existing codebases β be surgical and precise, respect surrounding code\\n- Don't change filenames or variables unnecessarily\\n- Don't add formatters/linters/tests to codebases that don't have them\\n</code_conventions>\\n\\n<testing>\\nAfter significant changes:\\n- Start testing as specific as possible to code changed, then broaden to build confidence\\n- Use self-verification: write unit tests, add output logs, or use debug statements to verify your solutions\\n- Run relevant test suite\\n- If tests fail, fix before continuing\\n- Check memory for test commands\\n- Run lint/typecheck if available (on precise targets when possible)\\n- For formatters: iterate max 3 times to get it right; if still failing, present correct solution and note formatting issue\\n- Suggest adding commands to memory if not found\\n- Don't fix unrelated bugs or test failures (not your responsibility)\\n</testing>\\n\\n<tool_usage>\\n- Default to using tools (ls, grep, view, agent, tests, web_fetch, etc.) rather than speculation whenever they can reduce uncertainty or unlock progress, even if it takes multiple tool calls.\\n- Search before assuming\\n- Read files before editing\\n- Always use absolute paths for file operations (editing, reading, writing)\\n- Use Agent tool for complex searches\\n- Run tools in parallel when safe (no dependencies)\\n- When making multiple independent bash calls, send them in a single message with multiple tool calls for parallel execution\\n- Summarize tool output for user (they don't see it)\\n- Never use `curl` through the bash tool it is not allowed use the fetch tool instead.\\n- Only use the tools you know exist.\\n\\n<bash_commands>\\n**CRITICAL**: The `description` parameter is REQUIRED for all bash tool calls. Always provide it.\\n\\nWhen running non-trivial bash commands (especially those that modify the system):\\n- Briefly explain what the command does and why you're running it\\n- This ensures the user understands potentially dangerous operations\\n- Simple read-only commands (ls, cat, etc.) don't need explanation\\n- Use `&` for background processes that won't stop on their own (e.g., `node server.js &`)\\n- Avoid interactive commands - use non-interactive versions (e.g., `npm init -y` not `npm init`)\\n- Combine related commands to save time (e.g., `git status && git diff HEAD && git log -n 3`)\\n</bash_commands>\\n</tool_usage>\\n\\n<proactiveness>\\nBalance autonomy with user intent:\\n- When asked to do something β do it fully (including ALL follow-ups and \\\"next steps\\\")\\n- Never describe what you'll do next - just do it\\n- When the user provides new information or clarification, incorporate it immediately and keep executing instead of stopping with an acknowledgement.\\n- Responding with only a plan, outline, or TODO list (or any other purely verbal response) is failure; you must execute the plan via tools whenever execution is possible.\\n- When asked how to approach β explain first, don't auto-implement\\n- After completing work β stop, don't explain (unless asked)\\n- Don't surprise user with unexpected actions\\n</proactiveness>\\n\\n<final_answers>\\nAdapt verbosity to match the work completed:\\n\\n**Default (under 4 lines)**:\\n- Simple questions or single-file changes\\n- Casual conversation, greetings, acknowledgements\\n- One-word answers when possible\\n\\n**More detail allowed (up to 10-15 lines)**:\\n- Large multi-file changes that need walkthrough\\n- Complex refactoring where rationale adds value\\n- Tasks where understanding the approach is important\\n- When mentioning unrelated bugs/issues found\\n- Suggesting logical next steps user might want\\n- Structure longer answers with Markdown sections and lists, and put all code, commands, and config in fenced code blocks.\\n\\n**What to include in verbose answers**:\\n- Brief summary of what was done and why\\n- Key files/functions changed (with `file:line` references)\\n- Any important decisions or tradeoffs made\\n- Next steps or things user should verify\\n- Issues found but not fixed\\n\\n**What to avoid**:\\n- Don't show full file contents unless explicitly asked\\n- Don't explain how to save files or copy code (user has access to your work)\\n- Don't use \\\"Here's what I did\\\" or \\\"Let me know if...\\\" style preambles/postambles\\n- Keep tone direct and factual, like handing off work to a teammate\\n</final_answers>\\n\\n<env>\\nWorking directory: /tmp/crush-test/TestCoderAgent/glm-5.1/sourcegraph_tool\\nIs directory a git repo: no\\nPlatform: linux\\nToday's date: 1/1/2025\\n\\n</env>\\n\\n\\n\\n<available_skills>\\n <skill>\\n <name>jq</name>\\n <description>Use when the user needs to query, filter, reshape, extract, create, or construct JSON data β including API responses, config files, log output, or any structured data β or when helping the user write or debug JSON transformations.</description>\\n <location>crush://skills/jq/SKILL.md</location>\\n <type>builtin</type>\\n </skill>\\n</available_skills>\\n\\n<skills_usage>\\nThe `<description>` of each skill is a TRIGGER β it tells you *when* a skill applies. It is NOT a specification of what the skill does or how to do it. The procedure, scripts, commands, references, and required flags live only in the SKILL.md body. You do not know what a skill actually does until you have read its SKILL.md.\\n\\nMANDATORY activation flow:\\n1. Scan `<available_skills>` against the current user task.\\n2. If any skill's `<description>` matches, call the View tool with its `<location>` EXACTLY as shown β before any other tool call that performs the task.\\n3. Read the entire SKILL.md and follow its instructions.\\n4. Only then execute the task, using the skill's prescribed commands/tools.\\n\\nDo NOT skip step 2 because you think you already know how to do the task. Do NOT infer a skill's behavior from its name or description. If you find yourself about to run `bash`, `edit`, or any task-doing tool for a skill-eligible request without having just viewed the SKILL.md, stop and load the skill first.\\n\\nBuiltin skills (type=builtin) use virtual `crush://skills/...` location identifiers. The \\\"crush://\\\" prefix is NOT a URL, network address, or MCP resource β it is a special internal identifier the View tool understands natively. Pass the `<location>` verbatim to View.\\n\\nDo not use MCP tools (including read_mcp_resource) to load skills.\\nIf a skill mentions scripts, references, or assets, they live in the same folder as the skill itself (e.g., scripts/, references/, assets/ subdirectories within the skill's folder).\\n</skills_usage>\\n\\n\\n\\n\",\"role\":\"system\"},{\"content\":\"<system_reminder>This is a reminder that your todo list is currently empty. DO NOT mention this to the user explicitly because they are already aware.\\nIf you are working on tasks that would benefit from a todo list please use the \\\"todos\\\" tool to create one.\\nIf not, please feel free to ignore. Again do not mention this message to the user.</system_reminder>\",\"role\":\"user\"},{\"content\":\"use sourcegraph to search for 'func main' in Go repositories\",\"role\":\"user\"},{\"tool_calls\":[{\"id\":\"call_7b76\",\"function\":{\"arguments\":\"{\\\"count\\\": 10, \\\"query\\\": \\\"func main lang:go\\\"}\",\"name\":\"sourcegraph\"},\"type\":\"function\"}],\"role\":\"assistant\"},{\"content\":\"# Sourcegraph Search Results\\n\\nFound 30 matches across 30 results\\n(Result limit reached, try a more specific query)\\n\\n## Result 1: github.com/callicoder/golang-tutorials/06-functions/01-function-declaration/main.go\\n\\nURL: /r/github.com/callicoder/golang-tutorials/-/blob/06-functions/01-function-declaration/main.go\\n\\n```\\n1| package main\\n2| \\n3| import \\\"fmt\\\"\\n4| \\n5| func avg(x float64, y float64) float64 {\\n6| \\treturn (x + y) / 2\\n7| }\\n8| func main() {\\n9| func main() {\\n10| \\tx := 5.75\\n11| \\ty := 6.25\\n12| \\n13| \\tresult := avg(x, y)\\n14| \\n15| \\tfmt.Printf(\\\"Average of %.2f and %.2f = %.2f\\\\n\\\", x, y, result)\\n16| }\\n17| \\n```\\n\\n```\\n0| package main\\n1| package main\\n2| \\n3| import \\\"fmt\\\"\\n4| \\n5| func avg(x float64, y float64) float64 {\\n6| \\treturn (x + y) / 2\\n7| }\\n8| \\n9| func main() {\\n10| \\tx := 5.75\\n```\\n\\n```\\n1| package main\\n2| \\n3| import \\\"fmt\\\"\\n4| func avg(x float64, y float64) float64 {\\n5| func avg(x float64, y float64) float64 {\\n6| \\treturn (x + y) / 2\\n7| }\\n8| \\n9| func main() {\\n10| \\tx := 5.75\\n11| \\ty := 6.25\\n12| \\n13| \\tresult := avg(x, y)\\n14| \\n```\\n\\n## Result 2: github.com/ondrajz/go-callvis/examples/main/main.go\\n\\nURL: /r/github.com/ondrajz/go-callvis/-/blob/examples/main/main.go\\n\\n```\\n1| package main\\n2| \\n3| import (\\n4| \\t\\\"github.com/ofabry/go-callvis/examples/main/mypkg\\\"\\n5| )\\n6| func main() {\\n7| func main() {\\n8| \\tfuncs()\\n9| \\tvar c calls\\n10| \\tc.execution()\\n11| \\tc.invocation()\\n12| }\\n13| \\n14| func funcs() {\\n15| \\tmypkg.Exported()\\n16| }\\n```\\n\\n```\\n1| package main\\n2| \\n3| import (\\n4| \\t\\\"github.com/ofabry/go-callvis/examples/main/mypkg\\\"\\n5| )\\n6| \\n7| \\tfuncs()\\n8| \\tfuncs()\\n9| \\tvar c calls\\n10| \\tc.execution()\\n11| \\tc.invocation()\\n12| }\\n13| \\n14| func funcs() {\\n15| \\tmypkg.Exported()\\n16| }\\n17| \\n```\\n\\n```\\n3| import (\\n4| \\t\\\"github.com/ofabry/go-callvis/examples/main/mypkg\\\"\\n5| )\\n6| \\n7| func main() {\\n8| \\tfuncs()\\n9| \\tvar c calls\\n10| \\tc.execution()\\n11| \\tc.invocation()\\n12| }\\n13| func funcs() {\\n14| func funcs() {\\n15| \\tmypkg.Exported()\\n16| }\\n17| \\n18| type calls struct{}\\n19| \\n20| func (calls) execution() {\\n21| \\tmypkg.Regular()\\n22| }\\n23| \\n```\\n\\n```\\n0| package main\\n1| package main\\n2| \\n3| import (\\n4| \\t\\\"github.com/ofabry/go-callvis/examples/main/mypkg\\\"\\n5| )\\n6| \\n7| func main() {\\n8| \\tfuncs()\\n9| \\tvar c calls\\n10| \\tc.execution()\\n```\\n\\n```\\n9| \\tvar c calls\\n10| \\tc.execution()\\n11| \\tc.invocation()\\n12| }\\n13| \\n14| func funcs() {\\n15| \\tmypkg.Exported()\\n16| }\\n17| \\n18| type calls struct{}\\n19| func (calls) execution() {\\n20| func (calls) execution() {\\n21| \\tmypkg.Regular()\\n22| }\\n23| \\n24| func (calls) invocation() {\\n25| \\tmypkg.T.Static()\\n26| \\tvar i mypkg.Iface = mypkg.T\\n27| \\ti.Dynamic()\\n28| }\\n29| \\n```\\n\\n```\\n13| \\n14| func funcs() {\\n15| \\tmypkg.Exported()\\n16| }\\n17| \\n18| type calls struct{}\\n19| \\n20| func (calls) execution() {\\n21| \\tmypkg.Regular()\\n22| }\\n23| func (calls) invocation() {\\n24| func (calls) invocation() {\\n25| \\tmypkg.T.Static()\\n26| \\tvar i mypkg.Iface = mypkg.T\\n27| \\ti.Dynamic()\\n28| }\\n29| \\n```\\n\\n```\\n1| package main\\n2| \\n3| \\t\\\"github.com/ofabry/go-callvis/examples/main/mypkg\\\"\\n4| \\t\\\"github.com/ofabry/go-callvis/examples/main/mypkg\\\"\\n5| )\\n6| \\n7| func main() {\\n8| \\tfuncs()\\n9| \\tvar c calls\\n10| \\tc.execution()\\n11| \\tc.invocation()\\n12| }\\n13| \\n```\\n\\n## Result 3: github.com/callicoder/golang-tutorials/13-methods/02-methods-are-functions/main.go\\n\\nURL: /r/github.com/callicoder/golang-tutorials/-/blob/13-methods/02-methods-are-functions/main.go\\n\\n```\\n12| func IsAboveFunc(p Point, y float64) bool {\\n13| \\treturn p.Y > y\\n14| }\\n15| \\n16| /*\\n17| Compare the above function with the corresponding method -\\n18| func (p Point) IsAbove(y float64) bool {\\n19| \\treturn p.Y > y\\n20| }\\n21| */\\n22| func main() {\\n23| func main() {\\n24| \\tp := Point{2.5, -3.0}\\n25| \\n26| \\tfmt.Println(\\\"Point : \\\", p)\\n27| \\n28| \\tfmt.Println(\\\"Is Point p located above the line y = 1.0 ? : \\\", IsAboveFunc(p, 1))\\n29| }\\n30| \\n```\\n\\n```\\n0| package main\\n1| package main\\n2| \\n3| import (\\n4| \\t\\\"fmt\\\"\\n5| )\\n6| \\n7| // Struct type - `Point`\\n8| type Point struct {\\n9| \\tX, Y float64\\n10| }\\n```\\n\\n```\\n1| package main\\n2| \\n3| import (\\n4| \\t\\\"fmt\\\"\\n5| )\\n6| \\n7| // Struct type - `Point`\\n8| type Point struct {\\n9| \\tX, Y float64\\n10| }\\n11| func IsAboveFunc(p Point, y float64) bool {\\n12| func IsAboveFunc(p Point, y float64) bool {\\n13| \\treturn p.Y > y\\n14| }\\n15| \\n16| /*\\n17| Compare the above function with the corresponding method -\\n18| func (p Point) IsAbove(y float64) bool {\\n19| \\treturn p.Y > y\\n20| }\\n21| */\\n```\\n\\n```\\n6| \\n7| // Struct type - `Point`\\n8| type Point struct {\\n9| \\tX, Y float64\\n10| }\\n11| \\n12| func IsAboveFunc(p Point, y float64) bool {\\n13| \\treturn p.Y > y\\n14| }\\n15| \\n16| Compare the above function with the corresponding method -\\n17| Compare the above function with the corresponding method -\\n18| func (p Point) IsAbove(y float64) bool {\\n19| \\treturn p.Y > y\\n20| }\\n21| */\\n22| \\n23| func main() {\\n24| \\tp := Point{2.5, -3.0}\\n25| \\n26| \\tfmt.Println(\\\"Point : \\\", p)\\n```\\n\\n```\\n7| // Struct type - `Point`\\n8| type Point struct {\\n9| \\tX, Y float64\\n10| }\\n11| \\n12| func IsAboveFunc(p Point, y float64) bool {\\n13| \\treturn p.Y > y\\n14| }\\n15| \\n16| /*\\n17| func (p Point) IsAbove(y float64) bool {\\n18| func (p Point) IsAbove(y float64) bool {\\n19| \\treturn p.Y > y\\n20| }\\n21| */\\n22| \\n23| func main() {\\n24| \\tp := Point{2.5, -3.0}\\n25| \\n26| \\tfmt.Println(\\\"Point : \\\", p)\\n27| \\n```\\n\\n```\\n17| Compare the above function with the corresponding method -\\n18| func (p Point) IsAbove(y float64) bool {\\n19| \\treturn p.Y > y\\n20| }\\n21| */\\n22| \\n23| func main() {\\n24| \\tp := Point{2.5, -3.0}\\n25| \\n26| \\tfmt.Println(\\\"Point : \\\", p)\\n27| \\tfmt.Println(\\\"Is Point p located above the line y = 1.0 ? : \\\", IsAboveFunc(p, 1))\\n28| \\tfmt.Println(\\\"Is Point p located above the line y = 1.0 ? : \\\", IsAboveFunc(p, 1))\\n29| }\\n30| \\n```\\n\\n## Result 4: github.com/agusrichard/go-workbook/functional-programming/content-2/main.go\\n\\nURL: /r/github.com/agusrichard/go-workbook/-/blob/functional-programming/content-2/main.go\\n\\n```\\n4| \\n5| func addition(x, y int) int {\\n6| \\treturn x + y\\n7| }\\n8| \\n9| func curryAddition(x int) func(y int) int {\\n10| \\treturn func(y int) int {\\n11| \\t\\treturn x + y\\n12| \\t}\\n13| }\\n14| func main() {\\n15| func main() {\\n16| \\tfmt.Println(addition(1, 2))\\n17| \\n18| \\tadd1 := curryAddition(1)\\n19| \\tadd10 := add1(10)\\n20| \\tfmt.Println(add10)\\n21| }\\n22| \\n```\\n\\n```\\n0| package main\\n1| package main\\n2| \\n3| import \\\"fmt\\\"\\n4| \\n5| func addition(x, y int) int {\\n6| \\treturn x + y\\n7| }\\n8| \\n9| func curryAddition(x int) func(y int) int {\\n10| \\treturn func(y int) int {\\n```\\n\\n```\\n1| package main\\n2| \\n3| import \\\"fmt\\\"\\n4| \\n5| func addition(x, y int) int {\\n6| \\treturn x + y\\n7| }\\n8| func curryAddition(x int) func(y int) int {\\n9| func curryAddition(x int) func(y int) int {\\n10| \\treturn func(y int) int {\\n11| \\t\\treturn x + y\\n12| \\t}\\n13| }\\n14| \\n15| func main() {\\n16| \\tfmt.Println(addition(1, 2))\\n17| \\n18| \\tadd1 := curryAddition(1)\\n```\\n\\n```\\n1| package main\\n2| \\n3| import \\\"fmt\\\"\\n4| \\n5| func addition(x, y int) int {\\n6| \\treturn x + y\\n7| }\\n8| \\n9| \\treturn func(y int) int {\\n10| \\treturn func(y int) int {\\n11| \\t\\treturn x + y\\n12| \\t}\\n13| }\\n14| \\n15| func main() {\\n16| \\tfmt.Println(addition(1, 2))\\n17| \\n18| \\tadd1 := curryAddition(1)\\n19| \\tadd10 := add1(10)\\n```\\n\\n```\\n1| package main\\n2| \\n3| import \\\"fmt\\\"\\n4| func addition(x, y int) int {\\n5| func addition(x, y int) int {\\n6| \\treturn x + y\\n7| }\\n8| \\n9| func curryAddition(x int) func(y int) int {\\n10| \\treturn func(y int) int {\\n11| \\t\\treturn x + y\\n12| \\t}\\n13| }\\n14| \\n```\\n\\n## Result 5: github.com/callicoder/golang-tutorials/13-methods/07-method-with-value-receiver-vs-function-with-value-argument/main.go\\n\\nURL: /r/github.com/callicoder/golang-tutorials/-/blob/13-methods/07-method-with-value-receiver-vs-function-with-value-argument/main.go\\n\\n```\\n9| \\tX, Y float64\\n10| }\\n11| \\n12| func (p Point) IsAbove(y float64) bool {\\n13| \\treturn p.Y > y\\n14| }\\n15| \\n16| func IsAboveFunc(p Point, y float64) bool {\\n17| \\treturn p.Y > y\\n18| }\\n19| func main() {\\n20| func main() {\\n21| \\tp := Point{0, 4}\\n22| \\tptr := &p\\n23| \\n24| \\tfmt.Println(\\\"Point p = \\\", p)\\n25| \\n26| \\t// Calling a Method with Value receiver\\n27| \\tp.IsAbove(1) // Valid\\n28| \\tptr.IsAbove(1) // Valid\\n29| \\n```\\n\\n```\\n0| package main\\n1| package main\\n2| \\n3| import (\\n4| \\t\\\"fmt\\\"\\n5| )\\n6| \\n7| // Struct type - `Point`\\n8| type Point struct {\\n9| \\tX, Y float64\\n10| }\\n```\\n\\n```\\n5| )\\n6| \\n7| // Struct type - `Point`\\n8| type Point struct {\\n9| \\tX, Y float64\\n10| }\\n11| \\n12| func (p Point) IsAbove(y float64) bool {\\n13| \\treturn p.Y > y\\n14| }\\n15| func IsAboveFunc(p Point, y float64) bool {\\n16| func IsAboveFunc(p Point, y float64) bool {\\n17| \\treturn p.Y > y\\n18| }\\n19| \\n20| func main() {\\n21| \\tp := Point{0, 4}\\n22| \\tptr := &p\\n23| \\n24| \\tfmt.Println(\\\"Point p = \\\", p)\\n25| \\n```\\n\\n```\\n19| \\n20| func main() {\\n21| \\tp := Point{0, 4}\\n22| \\tptr := &p\\n23| \\n24| \\tfmt.Println(\\\"Point p = \\\", p)\\n25| \\n26| \\t// Calling a Method with Value receiver\\n27| \\tp.IsAbove(1) // Valid\\n28| \\tptr.IsAbove(1) // Valid\\n29| \\t// Calling a Function with a Value argument\\n30| \\t// Calling a Function with a Value argument\\n31| \\tIsAboveFunc(p, 1) // Valid\\n32| \\t// IsAboveFunc(ptr, 1) // Not Valid\\n33| }\\n34| \\n```\\n\\n```\\n20| func main() {\\n21| \\tp := Point{0, 4}\\n22| \\tptr := &p\\n23| \\n24| \\tfmt.Println(\\\"Point p = \\\", p)\\n25| \\n26| \\t// Calling a Method with Value receiver\\n27| \\tp.IsAbove(1) // Valid\\n28| \\tptr.IsAbove(1) // Valid\\n29| \\n30| \\tIsAboveFunc(p, 1) // Valid\\n31| \\tIsAboveFunc(p, 1) // Valid\\n32| \\t// IsAboveFunc(ptr, 1) // Not Valid\\n33| }\\n34| \\n```\\n\\n\",\"tool_call_id\":\"call_7b76\",\"role\":\"tool\"}],\"model\":\"glm-5.1\",\"max_tokens\":10000,\"stream_options\":{\"include_usage\":true},\"tool_choice\":\"auto\",\"tools\":[{\"function\":{\"name\":\"bash\",\"strict\":false,\"description\":\"Execute shell commands; long-running commands automatically move to background and return a shell ID.\\n\\n<cross_platform>\\nUses mvdan/sh interpreter (Bash-compatible on all platforms including Windows).\\nUse forward slashes for paths: \\\"ls C:/foo/bar\\\" not \\\"ls C:\\\\foo\\\\bar\\\".\\nCommon shell builtins and core utils available on Windows.\\n</cross_platform>\\n\\n<execution_steps>\\n1. Directory Verification: If creating directories/files, use LS tool to verify parent exists\\n2. Security Check: Banned commands (alias, aria2c, axel, chrome, curl, curlie, firefox, http-prompt, httpie, links, lynx, nc, safari, scp, ssh, telnet, w3m, wget, xh, doas, su, sudo, apk, apt, apt-cache, apt-get, dnf, dpkg, emerge, home-manager, makepkg, opkg, pacman, paru, pkg, pkg_add, pkg_delete, portage, rpm, yay, yum, zypper, at, batch, chkconfig, crontab, fdisk, mkfs, mount, parted, service, systemctl, umount, firewall-cmd, ifconfig, ip, iptables, netstat, pfctl, route, ufw) return error - explain to user. Safe read-only commands execute without prompts\\n3. Command Execution: Execute with proper quoting, capture output\\n4. Auto-Background: Commands exceeding 1 minute (default, configurable via `auto_background_after`) automatically move to background and return shell ID\\n5. Output Processing: Truncate if exceeds 30000 characters\\n6. Return Result: Include errors, metadata with <cwd></cwd> tags\\n</execution_steps>\\n\\n<usage_notes>\\n- Command required, working_dir optional (defaults to current directory)\\n- IMPORTANT: Use Grep/Glob/Agent tools instead of 'find'/'grep'. Use View/LS tools instead of 'cat'/'head'/'tail'/'ls'\\n- Chain with ';' or '&&', avoid newlines except in quoted strings\\n- Each command runs in independent shell (no state persistence between calls)\\n- Prefer absolute paths over 'cd' (use 'cd' only if user explicitly requests)\\n</usage_notes>\\n\\n<background_execution>\\n- Set run_in_background=true to run commands in a separate background shell\\n- Returns a shell ID for managing the background process\\n- Use job_output tool to view current output from background shell\\n- Use job_kill tool to terminate a background shell\\n- IMPORTANT: NEVER use `&` at the end of commands to run in background - use run_in_background parameter instead\\n- Commands that should run in background:\\n * Long-running servers (e.g., `npm start`, `python -m http.server`, `node server.js`)\\n * Watch/monitoring tasks (e.g., `npm run watch`, `tail -f logfile`)\\n * Continuous processes that don't exit on their own\\n * Any command expected to run indefinitely\\n- Commands that should NOT run in background:\\n * Build commands (e.g., `npm run build`, `go build`)\\n * Test suites (e.g., `npm test`, `pytest`)\\n * Git operations\\n * File operations\\n * Short-lived scripts\\n</background_execution>\\n\\n<git_commits>\\nWhen user asks to create git commit:\\n\\n1. Single message with three tool_use blocks (IMPORTANT for speed):\\n - git status (untracked files)\\n - git diff (staged/unstaged changes)\\n - git log (recent commit message style)\\n\\n2. Add relevant untracked files to staging. Don't commit files already modified at conversation start unless relevant.\\n\\n3. Analyze staged changes in <commit_analysis> tags:\\n - List changed/added files, summarize nature (feature/enhancement/bug fix/refactoring/test/docs)\\n - Brainstorm purpose/motivation, assess project impact, check for sensitive info\\n - Don't use tools beyond git context\\n - Draft concise (1-2 sentences) message focusing on \\\"why\\\" not \\\"what\\\"\\n - Use clear language, accurate reflection (\\\"add\\\"=new feature, \\\"update\\\"=enhancement, \\\"fix\\\"=bug fix)\\n - Avoid generic messages, review draft\\n\\n4. Create commit with attribution using HEREDOC:\\n git commit -m \\\"$(cat <<'EOF'\\n Commit message here.\\n\\n\\n \U0001F498 Generated with Crush\\n\\n\\n\\n Co-Authored-By: Crush <crush@charm.land>\\n\\n\\n EOF\\n )\\\"\\n\\n5. If pre-commit hook fails, retry ONCE. If fails again, hook preventing commit. If succeeds but files modified, MUST amend.\\n\\n6. Run git status to verify.\\n\\nNotes: Use \\\"git commit -am\\\" when possible, don't stage unrelated files, NEVER update config, don't push, no -i flags, no empty commits, return empty response.\\n</git_commits>\\n\\n<pull_requests>\\nUse gh command for ALL GitHub tasks. When user asks to create PR:\\n\\n1. Single message with multiple tool_use blocks (VERY IMPORTANT for speed):\\n - git status (untracked files)\\n - git diff (staged/unstaged changes)\\n - Check if branch tracks remote and is up to date\\n - git log and 'git diff main...HEAD' (full commit history from main divergence)\\n\\n2. Create new branch if needed\\n3. Commit changes if needed\\n4. Push to remote with -u flag if needed\\n\\n5. Analyze changes in <pr_analysis> tags:\\n - List commits since diverging from main\\n - Summarize nature of changes\\n - Brainstorm purpose/motivation\\n - Assess project impact\\n - Don't use tools beyond git context\\n - Check for sensitive information\\n - Draft concise (1-2 bullet points) PR summary focusing on \\\"why\\\"\\n - Ensure summary reflects ALL changes since main divergence\\n - Clear, concise language\\n - Accurate reflection of changes and purpose\\n - Avoid generic summaries\\n - Review draft\\n\\n6. Create PR with gh pr create using HEREDOC:\\n gh pr create --title \\\"title\\\" --body \\\"$(cat <<'EOF'\\n\\n ## Summary\\n\\n <1-3 bullet points>\\n\\n ## Test plan\\n\\n [Checklist of TODOs...]\\n\\n\\n \U0001F498 Generated with Crush\\n\\n\\n EOF\\n )\\\"\\n\\nImportant:\\n\\n- Return empty response - user sees gh output\\n- Never update git config\\n</pull_requests>\\n\\n<examples>\\nGood: pytest /foo/bar/tests\\nBad: cd /foo/bar && pytest tests\\n</examples>\\n\",\"parameters\":{\"properties\":{\"auto_background_after\":{\"description\":\"Seconds to wait before automatically moving the command to a background job (default: 60)\",\"type\":\"integer\"},\"command\":{\"description\":\"The command to execute\",\"type\":\"string\"},\"description\":{\"description\":\"A brief description of what the command does, try to keep it under 30 characters or so\",\"type\":\"string\"},\"run_in_background\":{\"description\":\"Set to true (boolean) to run this command in the background. Use job_output to read the output later.\",\"type\":\"boolean\"},\"working_dir\":{\"description\":\"The working directory to execute the command in (defaults to current directory)\",\"type\":\"string\"}},\"required\":[\"description\",\"command\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"download\",\"strict\":false,\"description\":\"Download a URL directly to a local file (binary-safe, streaming, max 100MB); overwrites without warning. For reading content into context use fetch.\",\"parameters\":{\"properties\":{\"file_path\":{\"description\":\"The local file path where the downloaded content should be saved\",\"type\":\"string\"},\"timeout\":{\"description\":\"Optional timeout in seconds (max 600)\",\"type\":\"integer\"},\"url\":{\"description\":\"The URL to download from\",\"type\":\"string\"}},\"required\":[\"url\",\"file_path\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"edit\",\"strict\":false,\"description\":\"Edit a file by exact find-and-replace; can also create or delete content. For renames/moves use bash. For large edits use write.\",\"parameters\":{\"properties\":{\"file_path\":{\"description\":\"The absolute path to the file to modify\",\"type\":\"string\"},\"new_string\":{\"description\":\"The text to replace it with\",\"type\":\"string\"},\"old_string\":{\"description\":\"The text to replace\",\"type\":\"string\"},\"replace_all\":{\"description\":\"Replace all occurrences of old_string (default false)\",\"type\":\"boolean\"}},\"required\":[\"file_path\",\"old_string\",\"new_string\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"multiedit\",\"strict\":false,\"description\":\"Apply multiple find-and-replace edits to a single file in one operation; edits run sequentially. Prefer over edit for multiple changes to the same file. Same exact-match rules as edit apply.\",\"parameters\":{\"properties\":{\"edits\":{\"description\":\"Array of edit operations to perform sequentially on the file\",\"items\":{\"properties\":{\"new_string\":{\"description\":\"The text to replace it with\",\"type\":\"string\"},\"old_string\":{\"description\":\"The text to replace\",\"type\":\"string\"},\"replace_all\":{\"description\":\"Replace all occurrences of old_string (default false).\",\"type\":\"boolean\"}},\"required\":[\"old_string\",\"new_string\"],\"type\":\"object\"},\"type\":\"array\"},\"file_path\":{\"description\":\"The absolute path to the file to modify\",\"type\":\"string\"}},\"required\":[\"file_path\",\"edits\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"fetch\",\"strict\":false,\"description\":\"Fetch raw content from a URL as text, markdown, or html (max 5MB); no AI processing. For analysis or extraction use agentic_fetch.\",\"parameters\":{\"properties\":{\"format\":{\"description\":\"The format to return the content in (text, markdown, or html)\",\"type\":\"string\"},\"timeout\":{\"description\":\"Optional timeout in seconds (max 120)\",\"type\":\"integer\"},\"url\":{\"description\":\"The URL to fetch content from\",\"type\":\"string\"}},\"required\":[\"url\",\"format\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"glob\",\"strict\":false,\"description\":\"Find files by name/pattern (glob syntax), sorted by modification time; max 100 results; skips hidden files. Use grep to search file contents.\",\"parameters\":{\"properties\":{\"path\":{\"description\":\"The directory to search in. Defaults to the current working directory.\",\"type\":\"string\"},\"pattern\":{\"description\":\"The glob pattern to match files against\",\"type\":\"string\"}},\"required\":[\"pattern\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"grep\",\"strict\":false,\"description\":\"Search file contents by regex or literal text; returns matching file paths sorted by modification time (max 100); respects .gitignore. Use glob to filter by filename, not contents.\",\"parameters\":{\"properties\":{\"include\":{\"description\":\"File pattern to include in the search (e.g. \\\"*.js\\\", \\\"*.{ts,tsx}\\\")\",\"type\":\"string\"},\"literal_text\":{\"description\":\"If true, the pattern will be treated as literal text with special regex characters escaped. Default is false.\",\"type\":\"boolean\"},\"path\":{\"description\":\"The directory to search in. Defaults to the current working directory.\",\"type\":\"string\"},\"pattern\":{\"description\":\"The regex pattern to search for in file contents\",\"type\":\"string\"}},\"required\":[\"pattern\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"ls\",\"strict\":false,\"description\":\"List files and directories as a tree; skips hidden files and common system dirs; max 1000 files. Use glob to find files by pattern, grep to search contents.\",\"parameters\":{\"properties\":{\"depth\":{\"description\":\"The maximum depth to traverse\",\"type\":\"integer\"},\"ignore\":{\"description\":\"List of glob patterns to ignore\",\"items\":{\"type\":\"string\"},\"type\":\"array\"},\"path\":{\"description\":\"The path to the directory to list (defaults to current working directory)\",\"type\":\"string\"}},\"required\":[],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"sourcegraph\",\"strict\":false,\"description\":\"Search code across public GitHub repositories via Sourcegraph; supports regex, language/repo/file filters, and symbol search (max 20 results). Only searches public repos.\",\"parameters\":{\"properties\":{\"context_window\":{\"description\":\"The context around the match to return (default: 10 lines)\",\"type\":\"integer\"},\"count\":{\"description\":\"Optional number of results to return (default: 10, max: 20)\",\"type\":\"integer\"},\"query\":{\"description\":\"The Sourcegraph search query\",\"type\":\"string\"},\"timeout\":{\"description\":\"Optional timeout in seconds (max 120)\",\"type\":\"integer\"}},\"required\":[\"query\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"view\",\"strict\":false,\"description\":\"Read a file by path with line numbers; supports offset and line limit (default 2000, max 5MB); renders images (PNG, JPEG, GIF, BMP, SVG, WebP); use ls for directories.\",\"parameters\":{\"properties\":{\"file_path\":{\"description\":\"The path to the file to read\",\"type\":\"string\"},\"limit\":{\"description\":\"The number of lines to read (defaults to 2000)\",\"type\":\"integer\"},\"offset\":{\"description\":\"The line number to start reading from (0-based)\",\"type\":\"integer\"}},\"required\":[\"file_path\"],\"type\":\"object\"}},\"type\":\"function\"},{\"function\":{\"name\":\"write\",\"strict\":false,\"description\":\"Create or overwrite a file with given content; auto-creates parent dirs. Cannot append. Read the file first to avoid conflicts. For surgical changes use edit or multiedit.\",\"parameters\":{\"properties\":{\"content\":{\"description\":\"The content to write to the file\",\"type\":\"string\"},\"file_path\":{\"description\":\"The path to the file to write\",\"type\":\"string\"}},\"required\":[\"file_path\",\"content\"],\"type\":\"object\"}},\"type\":\"function\"}],\"stream\":true}"
136 headers:
137 Accept:
138 - application/json
139 Content-Type:
140 - application/json
141 User-Agent:
142 - Charm-Crush/devel (https://charm.land/crush)
143 url: https://hyper.charm.land/v1/chat/completions
144 method: POST
145 response:
146 proto: HTTP/2.0
147 proto_major: 2
148 proto_minor: 0
149 content_length: -1
150 uncompressed: true
151 body: |+
152 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"role":"assistant"},"finish_reason":null}]}
153
154 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"Found 30"},"finish_reason":null}]}
155
156 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" matches across 30"},"finish_reason":null}]}
157
158 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" results"},"finish_reason":null}]}
159
160 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" for"},"finish_reason":null}]}
161
162 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" `func main`"},"finish_reason":null}]}
163
164 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" in Go repositories"},"finish_reason":null}]}
165
166 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":". Here's"},"finish_reason":null}]}
167
168 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" a summary of the"},"finish_reason":null}]}
169
170 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" top results:\n\n|"},"finish_reason":null}]}
171
172 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" #"},"finish_reason":null}]}
173
174 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" | Repository"},"finish_reason":null}]}
175
176 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" | File | Description"},"finish_reason":null}]}
177
178 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" |\n|---|"},"finish_reason":null}]}
179
180 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"-----------|------"},"finish_reason":null}]}
181
182 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"|-------------"},"finish_reason":null}]}
183
184 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"|\n| "},"finish_reason":null}]}
185
186 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"1 | `cal"},"finish_reason":null}]}
187
188 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"licoder/golang"},"finish_reason":null}]}
189
190 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"-tutorials` |"},"finish_reason":null}]}
191
192 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" `06-functions/"},"finish_reason":null}]}
193
194 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"01-function-declaration"},"finish_reason":null}]}
195
196 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"/main.go` |"},"finish_reason":null}]}
197
198 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" Simple function declaration"},"finish_reason":null}]}
199
200 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" averaging two floats"},"finish_reason":null}]}
201
202 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" |\n| 2"},"finish_reason":null}]}
203
204 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" | `ond"},"finish_reason":null}]}
205
206 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"rajz/go-call"},"finish_reason":null}]}
207
208 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"vis` | `"},"finish_reason":null}]}
209
210 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"examples/main/main.go"},"finish_reason":null}]}
211
212 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"` | Call"},"finish_reason":null}]}
213
214 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" visualization"},"finish_reason":null}]}
215
216 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" example with"},"finish_reason":null}]}
217
218 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" methods"},"finish_reason":null}]}
219
220 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" on"},"finish_reason":null}]}
221
222 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" structs |\n| "},"finish_reason":null}]}
223
224 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"3 | `cal"},"finish_reason":null}]}
225
226 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"licoder/golang"},"finish_reason":null}]}
227
228 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"-tutorials` |"},"finish_reason":null}]}
229
230 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" `13-methods"},"finish_reason":null}]}
231
232 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"/02-methods"},"finish_reason":null}]}
233
234 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"-are-functions/main"},"finish_reason":null}]}
235
236 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":".go` | Demonstr"},"finish_reason":null}]}
237
238 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"ates methods vs functions"},"finish_reason":null}]}
239
240 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" on"},"finish_reason":null}]}
241
242 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" a `Point`"},"finish_reason":null}]}
243
244 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" struct |\n| "},"finish_reason":null}]}
245
246 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"4 | `ag"},"finish_reason":null}]}
247
248 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"usrichard/go"},"finish_reason":null}]}
249
250 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"-workbook` |"},"finish_reason":null}]}
251
252 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" `functional-programming"},"finish_reason":null}]}
253
254 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"/content-2/main"},"finish_reason":null}]}
255
256 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":".go` | Cur"},"finish_reason":null}]}
257
258 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"rying example with `"},"finish_reason":null}]}
259
260 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"addition` and"},"finish_reason":null}]}
261
262 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" `curryAdd"},"finish_reason":null}]}
263
264 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"ition` |\n|"},"finish_reason":null}]}
265
266 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" 5 | `"},"finish_reason":null}]}
267
268 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"callicoder/g"},"finish_reason":null}]}
269
270 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"olang-tutorials`"},"finish_reason":null}]}
271
272 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" | `13-method"},"finish_reason":null}]}
273
274 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"s/07-method"},"finish_reason":null}]}
275
276 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"-with"},"finish_reason":null}]}
277
278 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"-value-receiver-vs"},"finish_reason":null}]}
279
280 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"-function-with-value-"},"finish_reason":null}]}
281
282 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"argument/main.go`"},"finish_reason":null}]}
283
284 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" | Value receiver"},"finish_reason":null}]}
285
286 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" methods"},"finish_reason":null}]}
287
288 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" vs value"},"finish_reason":null}]}
289
290 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" argument"},"finish_reason":null}]}
291
292 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" functions |\n\nThe search"},"finish_reason":null}]}
293
294 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" returned results"},"finish_reason":null}]}
295
296 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" across tutorial"},"finish_reason":null}]}
297
298 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" repos"},"finish_reason":null}]}
299
300 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":", utility"},"finish_reason":null}]}
301
302 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" libraries, and example"},"finish_reason":null}]}
303
304 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" projects. All"},"finish_reason":null}]}
305
306 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" results"},"finish_reason":null}]}
307
308 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" show typical"},"finish_reason":null}]}
309
310 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" Go"},"finish_reason":null}]}
311
312 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" `func main()`"},"finish_reason":null}]}
313
314 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":" entry points in `"},"finish_reason":null}]}
315
316 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{"content":"package main`."},"finish_reason":null}]}
317
318 data: {"id":"chatcmpl-6ebde57950a4c68ac4162752","object":"chat.completion.chunk","created":0,"model":"glm-5.1","choices":[{"index":0,"delta":{},"finish_reason":"stop"}],"usage":{"prompt_tokens":3497,"completion_tokens":262,"total_tokens":11375}}
319
320 data: [DONE]
321
322 headers:
323 Content-Type:
324 - text/event-stream
325 status: 200 OK
326 code: 200
327 duration: 1.03733425s