Update app.py
Browse files
app.py
CHANGED
|
@@ -94,6 +94,9 @@ ctx = RecursiveContextManager(_resolve_repo_path())
|
|
| 94 |
|
| 95 |
def build_system_prompt() -> str:
|
| 96 |
stats = ctx.get_stats()
|
|
|
|
|
|
|
|
|
|
| 97 |
tools_doc = """
|
| 98 |
## Available Tools
|
| 99 |
- **search_code(query, n=5)**: Semantic search codebase.
|
|
@@ -104,8 +107,14 @@ def build_system_prompt() -> str:
|
|
| 104 |
- **write_file(path, content)**: Create/Update file (REQUIRES CHANGELOG).
|
| 105 |
- **shell_execute(command)**: Run shell command.
|
| 106 |
- **create_shadow_branch()**: Backup repository.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 107 |
"""
|
| 108 |
-
return f"""You are Clawdbot 🦞.
|
|
|
|
| 109 |
System Stats: {stats.get('total_files', 0)} files, {stats.get('conversations', 0)} memories.
|
| 110 |
{tools_doc}
|
| 111 |
Output Format: Use [TOOL: tool_name(arg="value")] for tools.
|
|
|
|
| 94 |
|
| 95 |
def build_system_prompt() -> str:
|
| 96 |
stats = ctx.get_stats()
|
| 97 |
+
|
| 98 |
+
# ... (Keep your notebook auto-loading logic here) ...
|
| 99 |
+
|
| 100 |
tools_doc = """
|
| 101 |
## Available Tools
|
| 102 |
- **search_code(query, n=5)**: Semantic search codebase.
|
|
|
|
| 107 |
- **write_file(path, content)**: Create/Update file (REQUIRES CHANGELOG).
|
| 108 |
- **shell_execute(command)**: Run shell command.
|
| 109 |
- **create_shadow_branch()**: Backup repository.
|
| 110 |
+
- **push_to_github(message)**: Save current state to GitHub.
|
| 111 |
+
- **pull_from_github(branch)**: Hard reset state from GitHub.
|
| 112 |
+
- **notebook_read()**: Read your working memory.
|
| 113 |
+
- **notebook_add(content)**: Add a note (max 25).
|
| 114 |
+
- **notebook_delete(index)**: Delete a note.
|
| 115 |
"""
|
| 116 |
+
return f"""You are Clawdbot 🦞. ... {tools_doc} ..."""
|
| 117 |
+
|
| 118 |
System Stats: {stats.get('total_files', 0)} files, {stats.get('conversations', 0)} memories.
|
| 119 |
{tools_doc}
|
| 120 |
Output Format: Use [TOOL: tool_name(arg="value")] for tools.
|