Modifications to many skills

This commit is contained in:
2026-05-09 19:36:03 +02:00
parent 5a30f4ca34
commit 44633ac6d6
62 changed files with 2213 additions and 345 deletions
+15 -3
View File
@@ -86,9 +86,21 @@ log(f'Received identity — name={agent.get("name", "?")!r}')
# ── Build identity markdown ───────────────────────────────────────────────────
def build_identity_markdown(a):
parts = [f'# {a["name"]}']
if a.get('role'): parts.append(f'**Role:** {a["role"]}')
if a.get('from_name'): parts.append(f'**Known as:** {a["from_name"]}')
name = a["name"]
known_as = a.get('from_name') or name
role = a.get('role', '')
# Lead with an unambiguous self-identity statement so the model does not
# default to "I am Agent Zero". The heading and opening sentence must be
# explicit — "# Gunnar" alone reads as a subject heading about the user.
parts = [
f'## Your identity',
f'Your name is {known_as}. You are not "Agent Zero" — that is the name of the '
f'framework you run on. Your name is {known_as}.',
]
if role:
parts.append(f'Your role is: {role}.')
if a.get('identity_document'): parts.append(f'\n## Background\n{a["identity_document"]}')
if a.get('job_description'): parts.append(f'\n## Job Description\n{a["job_description"]}')
if a.get('guardrails'): parts.append(f'\n## Guardrails\n{a["guardrails"]}')