gemcode 0.3.38__tar.gz → 0.3.39__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {gemcode-0.3.38/src/gemcode.egg-info → gemcode-0.3.39}/PKG-INFO +1 -1
- {gemcode-0.3.38 → gemcode-0.3.39}/pyproject.toml +1 -1
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/agent.py +22 -6
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tools/notes.py +4 -2
- {gemcode-0.3.38 → gemcode-0.3.39/src/gemcode.egg-info}/PKG-INFO +1 -1
- {gemcode-0.3.38 → gemcode-0.3.39}/LICENSE +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/MANIFEST.in +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/README.md +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/setup.cfg +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/__init__.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/__main__.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/audit.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/autocompact.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/callbacks.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/capability_routing.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/cli.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/compaction.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/computer_use/__init__.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/computer_use/browser_computer.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/config.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/context_budget.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/context_warning.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/credentials.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/hitl_session.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/hooks.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/interactions.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/invoke.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/kairos_daemon.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/limits.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/live_audio_engine.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/logging_config.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/mcp_loader.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/memory/__init__.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/memory/embedding_memory_service.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/memory/file_memory_service.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/modality_tools.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/model_errors.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/model_routing.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/openapi_loader.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/paths.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/permissions.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/plugins/__init__.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/plugins/terminal_hooks_plugin.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/plugins/tool_recovery_plugin.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/pricing.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/prompt_suggestions.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/query/__init__.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/query/config.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/query/deps.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/query/engine.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/query/stop_hooks.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/query/token_budget.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/query/transitions.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/refine.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/repl_commands.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/repl_slash.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/review_agent.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/session_runtime.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/session_store.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/slash_commands.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/thinking.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tool_prompt_manifest.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tool_registry.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tools/__init__.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tools/bash.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tools/browser.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tools/edit.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tools/filesystem.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tools/search.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tools/shell.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tools/shell_gate.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tools/subtask.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tools/think.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tools/todo.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tools/web.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tools_inspector.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/trust.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tui/input_handler.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tui/scrollback.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tui/spinner.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tui/welcome_banner.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/tui/welcome_rich.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/version.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/vertex.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/web/__init__.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/web/claude_sse_adapter.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/web/terminal_repl.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode/workspace_hints.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode.egg-info/SOURCES.txt +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode.egg-info/dependency_links.txt +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode.egg-info/entry_points.txt +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode.egg-info/requires.txt +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/src/gemcode.egg-info/top_level.txt +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_agent_instruction.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_autocompact.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_capability_routing.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_claude_web_adapter_sse.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_cli_init.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_computer_use_permissions.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_context_budget.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_context_warning.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_credentials.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_interactive_permission_ask.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_kairos_scheduler.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_modality_tools.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_model_error_retry.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_model_errors.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_model_routing.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_paths.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_permissions.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_prompt_suggestions.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_repl_commands.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_repl_slash.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_slash_commands.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_thinking_config.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_token_budget.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_tool_context_circulation.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_tools.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_tools_inspector.py +0 -0
- {gemcode-0.3.38 → gemcode-0.3.39}/tests/test_workspace_hints.py +0 -0
|
@@ -397,8 +397,24 @@ You run locally via the GemCode CLI. You are the same agent the user launched
|
|
|
397
397
|
{_build_runtime_facts(cfg)}
|
|
398
398
|
|
|
399
399
|
## Core identity and approach
|
|
400
|
-
|
|
401
|
-
|
|
400
|
+
|
|
401
|
+
### Classify before acting — choose the right mode for each message
|
|
402
|
+
|
|
403
|
+
Not every message is a coding task. Read the intent first and pick the right mode:
|
|
404
|
+
|
|
405
|
+
| Message type | Examples | Right action |
|
|
406
|
+
|---|---|---|
|
|
407
|
+
| **Greeting / chitchat** | "hi", "hii", "hello", "how are you", "thanks" | Reply directly. No tools. No orientation. |
|
|
408
|
+
| **Pure question / concept** | "what is a closure?", "explain OAuth", "which is better, Redis or Postgres?" | Answer from knowledge. No tools unless the answer requires inspecting *this* repo. |
|
|
409
|
+
| **Vague project question** | "how does auth work here?", "what's the folder structure?" | Call 1–2 read-only tools to find the answer, then reply. Keep it focused. |
|
|
410
|
+
| **Engineering task** | "add pagination", "fix the bug in auth.ts", "refactor the DB layer" | Full workflow: orient → plan → execute → verify. |
|
|
411
|
+
| **Analysis / research** | "analyse the whole backend", "summarise all API endpoints" | Systematic tool use: list → read → grep → synthesise. |
|
|
412
|
+
|
|
413
|
+
**NEVER call `list_directory`, `read_project_notes`, or any tool in response to a greeting or a general conversational message.** If you wouldn't call a tool to answer "hi" in a conversation, don't call it here either.
|
|
414
|
+
|
|
415
|
+
### Engineering task workflow
|
|
416
|
+
When the message is a real engineering task:
|
|
417
|
+
1. **Orient** — use `list_directory`, `glob_files`, `grep_content`, `read_file` to understand structure. These tools need **no permission** and are instant.
|
|
402
418
|
2. **Plan** — for complex tasks, call `todo_write` upfront to map out the work.
|
|
403
419
|
3. **Execute** — make the changes, run the checks, iterate.
|
|
404
420
|
4. **Verify** — confirm the result is correct before reporting done.
|
|
@@ -426,8 +442,9 @@ You have native deep thinking capability — use it actively:
|
|
|
426
442
|
- **For trade-off decisions** (which library, which pattern, which approach): reason through the pros/cons given this specific codebase.
|
|
427
443
|
|
|
428
444
|
## Interpreting requests
|
|
429
|
-
-
|
|
430
|
-
-
|
|
445
|
+
- **Greetings / conversational messages** ("hi", "hii", "hey", "thanks", "cool"): reply naturally with one sentence. Do NOT call any tools. Do NOT apologise for not running code.
|
|
446
|
+
- **General questions** that don't mention files or code ("what is X?", "explain Y"): answer from your knowledge directly. Only use tools if verifying something in *this specific repo* would materially improve the answer.
|
|
447
|
+
- **Engineering tasks** ("fix", "add", "refactor", "analyse", "debug"): infer from the repo — search, read, then act. Do not give abstract advice when concrete files exist.
|
|
431
448
|
- If the user refers to symbols or behaviors, **find them** with `glob_files`/`grep_content`/`list_directory` — never ask them to paste paths you can discover yourself.
|
|
432
449
|
- **Never propose edits to files you haven't read.** Read first, then edit.
|
|
433
450
|
- When something fails, diagnose (re-read the error, check assumptions) before switching strategy. Do not repeat the same failed call.
|
|
@@ -615,8 +632,7 @@ You have two tools to persist project insights across sessions, like Claude Code
|
|
|
615
632
|
Call this **immediately** when you discover something useful — not just at the end of tasks.
|
|
616
633
|
Notes are loaded at session start so future sessions inherit this knowledge.
|
|
617
634
|
|
|
618
|
-
- **`read_project_notes()`** — read current notes
|
|
619
|
-
If notes exist and you haven't read them yet, read them first to avoid re-discovering known information."""
|
|
635
|
+
- **`read_project_notes()`** — read current notes **only when starting a real engineering task** (editing, debugging, building). Do NOT call this for greetings or general questions. If notes exist and you're about to work on a task, read them once to avoid re-discovering known information."""
|
|
620
636
|
|
|
621
637
|
# Inject capability-specific strategy sections only when those caps are on.
|
|
622
638
|
if getattr(cfg, "enable_computer_use", False):
|
|
@@ -86,8 +86,10 @@ def build_notes_tools(project_root: Path) -> list:
|
|
|
86
86
|
"""
|
|
87
87
|
Read the current contents of .gemcode/notes.md.
|
|
88
88
|
|
|
89
|
-
|
|
90
|
-
|
|
89
|
+
ONLY call this when you are about to work on an actual engineering task
|
|
90
|
+
(editing files, debugging, building something) and want to avoid re-discovering
|
|
91
|
+
already-known project facts. Do NOT call this for greetings, chitchat, or
|
|
92
|
+
general questions that don't require project context.
|
|
91
93
|
|
|
92
94
|
Returns the full notes content as a string, or an empty string if no notes exist.
|
|
93
95
|
"""
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|