Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .agents/autonomy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@ human_gates:
elevation:
required_before: [public]
approval_stage: elevation
architecture:
required_before: [invoke_skill, side_effect]
approval_stage: architecture
Comment thread
cursor[bot] marked this conversation as resolved.
package:
required_before: [side_effect]
approval_stage: package
Expand All @@ -72,5 +75,8 @@ actions:
- human.gate.requested
- human.gate.approved
- human.gate.denied
- human.interaction.requested
- human.interaction.answered
- human.interaction.cleared
- choreography.resolve
- autonomy.blocked
57 changes: 47 additions & 10 deletions .agents/choreography.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
# Coreografia — Sky-Forge v3
# Autonomia explícita + gates + triggers para choreograph-agents.ps1
version: 3
updated: 2026-07-04
# Coreografia — Sky-Forge v3.1
# Autonomia explícita + gates + triggers + pontos de interação HITL
version: 3.1
updated: 2026-07-28
policy: |
Agentes operam dentro do nível de autonomia declarado. Ações acima do nível
ou sem human gate são bloqueadas e registradas em .sky/audit/{slug}/events.jsonl.
sky-host roteia; especialistas executam; domínio só consulta.
Decision points (.agents/interaction-points.yaml): pausar e elicitar com
AskQuestion (Cursor) ou fallback numerado antes de prosseguir.

autonomy_ref: .agents/autonomy.yaml
interaction_points_ref: .agents/interaction-points.yaml

triggers:
- id: manual
Expand All @@ -18,48 +21,80 @@ triggers:
description: overall_readiness cruzou limiar
- id: post_export
description: Após export bem-sucedido
- id: post_assess
description: Após sky assess — elicitar assess.next_action
- id: post_attach
description: Após sky attach — elicitar brownfield.after_attach (se sem assess)
Comment on lines +24 to +27

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Accept the newly declared choreography triggers

Add post_assess and post_attach to the trigger values accepted by scripts/agents/choreograph-agents.ps1:13; otherwise any caller attempting to resolve either newly declared trigger is rejected during PowerShell parameter binding, so the intake-sessions rule can never be activated through those trigger names.

Useful? React with 👍 / 👎.

- id: hook_stop
description: Hook Cursor stop — auditoria passiva

interaction_hooks:
- trigger: manual
when: arrival_or_unclear_intent
point: arrival.intent
agent: sky-host
- trigger: post_attach
point: brownfield.after_attach
agent: sky-host
- trigger: post_assess
point: assess.next_action
agent: sky-host
- trigger: maturity_gate
when: open_to_elevation
point: elevate.confirm
agent: sky-host
- trigger: manual
when: export_requested
point: deliver.export_scope
agent: delivery-steward
- trigger: manual
when: public_publish_requested
point: showcase.privacy
agent: showcase-curator

rules:
- id: experience-host
when: [manual, path_change]
paths:
- sky.config.yaml
- docs/_meta/USER_JOURNEY.md
- docs/_meta/OUTPUTS_AND_SHOWCASE.md
- docs/_meta/SKY_INTERACT.md
- .agents/interaction-points.yaml
agents:
- id: sky-host
type: operational
autonomy: [observe, route]
max_autonomy: route
skills: [sky-interact]
- id: delivery-steward
type: operational
autonomy: [observe, activate, invoke_skill]
max_autonomy: invoke_skill
skills: [sky-deliver, sky-export, sky-validate]
skills: [sky-deliver, sky-export, sky-validate, sky-interact]
requires_gate: [package]
- id: showcase-curator
type: operational
autonomy: [observe, activate, invoke_skill]
max_autonomy: invoke_skill
skills: [sky-publish, sky-showcase]
skills: [sky-publish, sky-showcase, sky-interact]
requires_gate: [public_showcase]

- id: intake-sessions
when: [manual, path_change]
when: [manual, path_change, post_assess, post_attach]
paths:
- .sky/sessions/**
agents:
- id: sky-host
type: operational
autonomy: [observe, route]
max_autonomy: route
skills: [sky-interact]
- id: intake-conductor
type: operational
autonomy: [observe, activate, invoke_skill]
max_autonomy: activate
skills: [sky-intake, sky-approve, sky-elevate]
skills: [sky-intake, sky-approve, sky-elevate, sky-interact]
requires_gate: [brief]
- id: sky-elevator
type: domain
Expand Down Expand Up @@ -104,12 +139,13 @@ rules:
type: operational
autonomy: [observe, activate, invoke_skill, public]
max_autonomy: public
skills: [sky-publish, sky-showcase]
skills: [sky-publish, sky-showcase, sky-interact]
requires_gate: [public_showcase]
- id: sky-host
type: operational
autonomy: [route]
max_autonomy: route
skills: [sky-interact]

- id: outputs-package
when: [path_change, post_export, maturity_gate]
Expand All @@ -121,7 +157,7 @@ rules:
type: operational
autonomy: [observe, activate, invoke_skill, side_effect]
max_autonomy: side_effect
skills: [sky-deliver, sky-export, sky-validate]
skills: [sky-deliver, sky-export, sky-validate, sky-interact]
requires_gate: [package]
- id: showcase-curator
type: operational
Expand Down Expand Up @@ -265,6 +301,7 @@ party_mode:
policy: |
Reúne consultas paralelas de domínio. O host apresenta síntese — nunca export + publish
no mesmo turno. Ativado por fase UX (journey.yaml current_phase).
Preferir AskQuestion para a decisão resultante da party.
sessions:
- id: elevation-party
label: Elevação colaborativa
Expand Down
192 changes: 192 additions & 0 deletions .agents/interaction-points.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,192 @@
# Pontos de interação HITL — Sky-Forge
# Agentes: preferir AskQuestion (Cursor UI); fallback = opções numeradas no chat.
# Fonte: docs/_meta/SKY_INTERACT.md · skill sky-interact
version: "1.0"
updated: 2026-07-28

policy: |
Em todo decision_point listado aqui, o agente DEVE pausar e elicitar
com AskQuestion quando a ferramenta estiver disponível no turno.
Se AskQuestion não existir (modelo/modo), usar o formato sky-host
(máx. 4 opções numeradas + "Responda com o número…").
Uma pergunta por turno. Nunca empilhar gates no mesmo turno.
Após a escolha: atualizar journey.yaml (pending_interaction resolved +
next_suggested_actions) e registrar human.interaction.answered na auditoria.

defaults:
max_options: 4
allow_freeform_escape: true
freeform_label: "Outra coisa (vou digitar)"
ask_question_tool: AskQuestion
fallback: numbered_chat

points:
- id: arrival.intent
phase: arrival
agent: sky-host
skill: sky-interact
when: Sem slug / chegada / usuário abre Sky-Forge sem pedido claro
prompt: O que você quer fazer no Sky-Forge agora?
options:
- id: new_idea
label: Começar ideia nova (intake)
routes_to: intake-conductor
- id: resume
label: Retomar sessão existente
routes_to: sky-host
- id: brownfield_repo
label: Analisar / anexar repositório existente
routes_to: intake-conductor
- id: status_only
label: Só ver status de um projeto
routes_to: sky-host

- id: brownfield.path_confirm
phase: shape
agent: sky-host
skill: sky-interact
when: Usuário pediu attach/assess sem WorkspacePath claro
prompt: Qual repositório devemos usar?
options:
- id: current_workspace
label: Este workspace aberto no Cursor
- id: paste_path
label: Vou informar o caminho
- id: cancel
label: Cancelar por agora

- id: brownfield.after_attach
phase: shape
agent: sky-host
skill: sky-interact
when: Após sky attach bem-sucedido
prompt: Host plugin anexado. Próximo passo?
options:
- id: run_assess
label: Rodar assessment do repositório
command: ./scripts/sky/sky.ps1 assess -Slug {slug} -WorkspacePath {workspace}
- id: deepen_problem
label: Contar o problema de evolução (intake)
routes_to: intake-conductor
- id: status
label: Ver maturidade / status
command: ./scripts/sky/sky.ps1 status -Slug {slug}
- id: later
label: Parar por aqui

- id: assess.next_action
phase: shape
agent: sky-host
skill: sky-interact
when: Após sky assess (platform-assessment.yaml gerado)
prompt: Assessment pronto. O que prefere agora?
options:
- id: deepen_top_gap
label: Aprofundar a principal lacuna detectada
routes_to: intake-conductor
- id: seed_roadmap
label: Gerar roadmap de evolução (draft)
command: ./scripts/sky/sky.ps1 seed-roadmap -Slug {slug}
- id: elevate
label: Explorar elevação / índices SKY
routes_to: sky-elevator
- id: status
label: Só revisar o status
command: ./scripts/sky/sky.ps1 status -Slug {slug}

- id: intake.deepen_gap
phase: shape
agent: intake-conductor
skill: sky-interact
when: Há lacunas de maturidade e o usuário não escolheu qual preencher
prompt: Qual lacuna quer aprofundar agora?
options_source: maturity.top_gaps
options_fallback:
- id: business
label: Negócio / problema / stakeholders
- id: product
label: Produto / jornadas / requisitos
- id: ux_design
label: UX / acessibilidade
Comment thread
cursor[bot] marked this conversation as resolved.
- id: something_else
label: Outra coisa (vou digitar)

- id: elevate.confirm
phase: elevate
agent: sky-host
skill: sky-interact
when: open_to_elevation true e sky-elevator tem sugestões ai_suggested
prompt: Quer explorar conexões de elevação (opcional)?
options:
- id: explore
label: Sim, explorar sugestões
routes_to: sky-elevator
- id: skip
label: Não agora — seguir no produto
routes_to: intake-conductor
- id: disable
label: Prefiro não elevar neste projeto
sets: policies.open_to_elevation=false

- id: gate.approve_stage
phase: any
agent: sky-host
skill: sky-interact
when: Ação bloqueada por human gate (brief|elevation|architecture|package|public_showcase)
prompt: Há um gate humano pendente. Como seguir?
options:
- id: approve
label: Aprovar este stage agora
command: ./scripts/sky/sky.ps1 approve -Slug {slug} -Stage {stage}
- id: explain
label: Explicar o que o gate protege
- id: defer
label: Deixar para depois
Comment thread
coderabbitai[bot] marked this conversation as resolved.

- id: deliver.export_scope
phase: deliver
agent: delivery-steward
skill: sky-interact
when: Usuário pediu export sem escopo claro
prompt: Como quer o pacote de entrega?
options:
- id: partial
label: Parcial (pronto para handoff cedo)
command: ./scripts/sky/sky.ps1 export -Slug {slug} -Completeness partial
- id: full
label: Completo (quando readiness permitir)
command: ./scripts/sky/sky.ps1 export -Slug {slug} -Completeness full
- id: for_ai
label: Pacote para IA (-ForAI)
command: ./scripts/sky/sky.ps1 export -Slug {slug} -ForAI -Scope essential
- id: cancel
label: Ainda não exportar

- id: showcase.privacy
phase: showcase
agent: showcase-curator
skill: sky-interact
when: Antes de publish -Public
prompt: Sobre privacidade do preview público…
options:
- id: private_only
label: Manter privado (só máquina / pasta externa)
- id: public_ok
label: Autorizo publish -Public no showcase
requires_gate: public_showcase
- id: ask_later
label: Decidir depois

- id: implement.agentic_repo
phase: implement
agent: repo-scaffolder
skill: sky-interact
when: agentic-repo-recommendation tier recommended|suggested
prompt: Recomendamos ARAH Harness neste repo. Quer instalar antes do scaffold/link?
options:
- id: install_arah
label: Sim — orientar instalação do ARAH Harness
- id: skip_arah
label: Seguir sem ARAH por agora
- id: explain
label: Explicar o que é o ARAH Harness
6 changes: 6 additions & 0 deletions .agents/operational/intake-conductor.agent.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ skills:
- sky-intake
- sky-approve
- sky-elevate
- sky-interact
- sky-rag-query
domain_consults:
- sky-elevator
Expand Down Expand Up @@ -47,6 +48,11 @@ elicitation:
- invite_elevation_when_open_to_elevation
- never_skip_business_minimum
- handoff_to_delivery_when_readiness_partial
- prefer_ask_question_on_decision_points
interaction_points:
- intake.deepen_gap
- elevate.confirm
- assess.next_action
guardrails:
no_confirmed_requirements_without_user_ok: true
respect_elevation_policy: true
Loading
Loading