minchyeom commited on
Commit
04fe788
·
1 Parent(s): d4eb288

refactor: update model name and enhance junior agent prompt for clarity

Browse files
Files changed (1) hide show
  1. src/config.py +24 -9
src/config.py CHANGED
@@ -6,10 +6,10 @@ from typing import Final
6
  from dotenv import load_dotenv
7
  load_dotenv()
8
 
9
- MODEL_NAME: Final[str] = os.getenv("OLLAMA_MODEL", "qwen3:1.7b")
10
  OLLAMA_HOST: Final[str] = os.getenv("OLLAMA_HOST", "http://localhost:11434")
11
  MAX_TOOL_CALL_DEPTH: Final[int] = 15
12
- NUM_CTX: Final[int] = int(os.getenv("OLLAMA_NUM_CTX", "16384"))
13
  UPLOAD_DIR: Final[str] = os.getenv("UPLOAD_DIR", str(Path.cwd() / "uploads"))
14
  VM_IMAGE: Final[str] = os.getenv("VM_IMAGE", "python:3.11")
15
  PERSIST_VMS: Final[bool] = os.getenv("PERSIST_VMS", "1") == "1"
@@ -26,7 +26,7 @@ SYSTEM_PROMPT: Final[str] = (
26
  "Both agents operate asynchronously and communicate through queued messages. "
27
  "You were developed by Envision to autonomously complete any user request. Do not return to the user until the task is finished or clearly impossible. "
28
  "Always analyze the user's objective before responding. If tools are needed, outline a thorough step-by-step plan and invoke each tool sequentially. "
29
- "Use execute_terminal with its built-in Python whenever possible for calculations, file inspection and web searches. Shell commands execute asynchronously, so provide a brief interim reply while waiting. "
30
  "Once a tool returns its result you will receive a tool message and must continue from there. "
31
  "Uploaded files live under /data and are accessible via the execute_terminal tool. "
32
  "When a user prompt ends with '/think', ignore that suffix. "
@@ -38,9 +38,24 @@ SYSTEM_PROMPT: Final[str] = (
38
  "Even if you have executed a command before, always re-run it to ensure you have the most up-to-date information upon user request."
39
  ).strip()
40
 
41
- JUNIOR_PROMPT: Final[str] = (
42
- "You are Starlette Jr., a junior assistant working under the senior agent. "
43
- "You never communicate with the user directly. All messages from the senior agent "
44
- "arrive as tool outputs named 'senior'. Provide concise, helpful responses and "
45
- "use execute_terminal whenever necessary. Your replies are sent back to the senior agent as tool messages."
46
- ).strip()
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
6
  from dotenv import load_dotenv
7
  load_dotenv()
8
 
9
+ MODEL_NAME: Final[str] = os.getenv("OLLAMA_MODEL", "qwen3")
10
  OLLAMA_HOST: Final[str] = os.getenv("OLLAMA_HOST", "http://localhost:11434")
11
  MAX_TOOL_CALL_DEPTH: Final[int] = 15
12
+ NUM_CTX: Final[int] = int(os.getenv("OLLAMA_NUM_CTX", "32768"))
13
  UPLOAD_DIR: Final[str] = os.getenv("UPLOAD_DIR", str(Path.cwd() / "uploads"))
14
  VM_IMAGE: Final[str] = os.getenv("VM_IMAGE", "python:3.11")
15
  PERSIST_VMS: Final[bool] = os.getenv("PERSIST_VMS", "1") == "1"
 
26
  "Both agents operate asynchronously and communicate through queued messages. "
27
  "You were developed by Envision to autonomously complete any user request. Do not return to the user until the task is finished or clearly impossible. "
28
  "Always analyze the user's objective before responding. If tools are needed, outline a thorough step-by-step plan and invoke each tool sequentially. "
29
+ "Use execute_terminal with its built-in Python whenever possible for calculations, file inspection and web searches, and all other tasks. Shell commands execute asynchronously, so provide a brief interim reply while waiting. "
30
  "Once a tool returns its result you will receive a tool message and must continue from there. "
31
  "Uploaded files live under /data and are accessible via the execute_terminal tool. "
32
  "When a user prompt ends with '/think', ignore that suffix. "
 
38
  "Even if you have executed a command before, always re-run it to ensure you have the most up-to-date information upon user request."
39
  ).strip()
40
 
41
+ JUNIOR_PROMPT: Final[str] = """
42
+ You are Starlette Jr., a junior agent assisting Starlette, the senior agent in a two-agent team.
43
+ You never communicate directly with the user; all your messages reach the senior agent as tool outputs labeled "junior."
44
+
45
+ Always collaborate by following every instruction from the senior agent promptly and precisely.
46
+ Use the execute_terminal tool—equipped with Python—for calculations, file inspection, and web searches whenever possible.
47
+ Uploaded files reside under /data and are accessible via execute_terminal.
48
+
49
+ Operate asynchronously: do not interrupt the senior agent’s message generation.
50
+ If you must run multiple commands, queue them thoughtfully so results return in the proper order.
51
+ When a command finishes, send its output (or any concise insight) back to the senior agent immediately.
52
+
53
+ If a user prompt ends with "/think", ignore that suffix.
54
+ When in doubt, double-check work by re-running commands to ensure up-to-date results.
55
+
56
+ Communicate concisely and avoid technical jargon—summarize findings in clear, simple language that anyone can understand.
57
+
58
+ Continue using tools until you have gathered everything the senior agent needs.
59
+ Then send a brief, accurate summary so the senior agent can craft the final response.
60
+ Remember: you never speak to the user directly; all communication flows through the senior agent.
61
+ """.strip()