How cadubra2/redator-de-pecas-multiagente works
This is a multi-agent legal-brief drafting and evaluation system. A case’s source materials and the firm’s writing guidance feed a drafting loop: a redactor produces a brief, a code-based style checker and reviewer/cr critic cycle refine it, and three blind judges score it. The orchestrator aggregates their assessments into consensus feedback, keeps the highest-scoring version, and writes results. The README documents the major capabilities and flow; sampled source confirms key orchestration, provider, and consensus behavior, but not every prompt or stopping rule.
Main entry points: loop.py Drafting loop · provedores.py LLM providers · SKILL.md Firm voice skill · __main__.py CLI entry
Components 18
Drafting workflow
- Case sources
casos - Redator
papeis - Style checker
skill/scripts/verificar.py - Revisor
papeis - Crítico
papeis
Writing guidance
- Firm voice skill
skill/SKILL.md - Style references
skill/references - Scoring rubric
rubrica/rubrica.md
Orchestration
- Drafting loop
orquestrador/loop.py - CLI entry
orquestrador/__main__.py - LLM providers
orquestrador/provedores.py
Evaluation and results
- Blind judges
papeis/juiz-cego.md - Consensus grouping
orquestrador/consenso.py - Best-version selection
orquestrador/loop.py - Run results
orquestrador/loop.py - Sample evolution
exemplos/evolucao-parnaiba
Other components
- Lawyer
- LLM services
Connections 21
- Lawyer → CLI entry: starts run
README.md - CLI entry → Drafting loop: configures and runs
orquestrador/__main__.py - Drafting loop → Case sources: reads case facts
orquestrador/loop.py - Drafting loop → Redator: requests draft
README.md - Drafting loop → Firm voice skill: provides guidance
orquestrador/loop.py - Drafting loop → Style references: uses writing guidance
README.md - Drafting loop → Style checker: checks draft
orquestrador/loop.py - Drafting loop → Revisor: requests revisions
README.md - Drafting loop → Crítico: requests approval
README.md - Drafting loop → Blind judges: requests blind scores
orquestrador/loop.py - Drafting loop → Scoring rubric: supplies scoring rubric
orquestrador/loop.py - Drafting loop → LLM providers: routes role calls
orquestrador/loop.py - LLM providers → LLM services: calls configured model
orquestrador/provedores.py - LLM providers → Run results: reads recorded replies
orquestrador/provedores.py - Drafting loop → Consensus grouping: groups judge findings
orquestrador/loop.py - Consensus grouping → Redator: formats revision feedback
orquestrador/consenso.py - Drafting loop → Best-version selection: compares round scores
orquestrador/loop.py - Best-version selection → Run results: writes best brief
orquestrador/loop.py - Drafting loop → Run results: writes scores and notes
orquestrador/loop.py - Sample evolution → Lawyer: illustrates score history
README.md - Firm voice skill → Style references: supplemented by