[kit] Add Forge for Freelance Services Agreement & Invoice Generation [mission-possible]#152
[kit] Add Forge for Freelance Services Agreement & Invoice Generation [mission-possible]#152cyber-turtle wants to merge 24 commits intoLamatic:mainfrom
Conversation
…signature placement
|
Important Review skippedAuto reviews are limited based on label configuration. 🏷️ Required labels (at least one) (1)
Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI (base), Organization UI (inherited) Review profile: ASSERTIVE Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Tip 💬 Introducing Slack Agent: The best way for teams to turn conversations into code.Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.
Built for teams:
One agent for your entire SDLC. Right inside Slack. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Pull request overview
Adds a new Forge kit to AgentKit: a 4-step Lamatic + Next.js wizard that collects project details, runs pricing + governing-law analysis, and generates a services agreement and invoice with signature + export UI.
Changes:
- Added 4 Lamatic flow definitions (pricing, tradeoff, contract, invoice) with prompts, constitutions, and model-config placeholders.
- Added a Next.js (App Router) frontend implementing the 4-step wizard, previews, signature capture, and export.
- Added kit metadata/docs (
lamatic.config.ts,agent.md,README.md) and local env scaffolding.
Reviewed changes
Copilot reviewed 54 out of 58 changed files in this pull request and generated 23 comments.
Show a summary per file
| File | Description |
|---|---|
| kits/forge/prompts/forge-tradeoff_llmnode-tradeoff_user_1.md | Tradeoff flow user prompt template. |
| kits/forge/prompts/forge-tradeoff_llmnode-tradeoff_system_0.md | Tradeoff flow system prompt + JSON output constraints. |
| kits/forge/prompts/forge-pricing_llmnode-pricing_user_1.md | Pricing flow user prompt template. |
| kits/forge/prompts/forge-pricing_llmnode-pricing_system_0.md | Pricing flow system prompt + JSON schema expectations. |
| kits/forge/prompts/forge-invoice_llmnode-invoice_user_1.md | Invoice flow user prompt template. |
| kits/forge/prompts/forge-invoice_llmnode-invoice_system_0.md | Invoice flow system prompt + strict JSON rules. |
| kits/forge/prompts/forge-contract_llmnode-contract_user_1.md | Contract flow user prompt template. |
| kits/forge/prompts/forge-contract_llmnode-contract_system_0.md | Contract flow system prompt describing 13-section contract JSON output. |
| kits/forge/model-configs/forge-tradeoff_llmnode-tradeoff_generative-model-name.ts | Placeholder model-config for tradeoff LLM node. |
| kits/forge/model-configs/forge-pricing_llmnode-pricing_generative-model-name.ts | Placeholder model-config for pricing LLM node. |
| kits/forge/model-configs/forge-invoice_llmnode-invoice_generative-model-name.ts | Placeholder model-config for invoice LLM node. |
| kits/forge/model-configs/forge-contract_llmnode-contract_generative-model-name.ts | Placeholder model-config for contract LLM node. |
| kits/forge/lamatic.config.ts | Kit metadata (name/steps/env keys/links). |
| kits/forge/flows/forge-tradeoff.ts | Lamatic flow graph for governing-law options. |
| kits/forge/flows/forge-pricing.ts | Lamatic flow graph for pricing analysis. |
| kits/forge/flows/forge-invoice.ts | Lamatic flow graph for invoice generation. |
| kits/forge/flows/forge-contract.ts | Lamatic flow graph for contract generation. |
| kits/forge/constitutions/default.md | Kit constitution/guardrails for agent behavior. |
| kits/forge/apps/tsconfig.json | Next.js app TS config. |
| kits/forge/apps/tailwind.config.js | Tailwind theme + content config. |
| kits/forge/apps/public/forge2.svg | App logo asset. |
| kits/forge/apps/postcss.config.js | PostCSS config for Tailwind. |
| kits/forge/apps/package.json | App dependencies/scripts. |
| kits/forge/apps/orchestrate.js | Centralized env-driven flow configuration. |
| kits/forge/apps/next.config.mjs | Next.js config (TS/build/image settings). |
| kits/forge/apps/lib/utils.ts | Tailwind/className helper (cn). |
| kits/forge/apps/lib/types.ts | Shared session + document data types. |
| kits/forge/apps/lib/storage.ts | localStorage session persistence helpers. |
| kits/forge/apps/lib/lamatic.ts | Client helper to call /api/flow. |
| kits/forge/apps/lib/lamatic-client.ts | Server-side Lamatic SDK client init. |
| kits/forge/apps/components/wizard/StepIndicator.tsx | Wizard step indicator UI. |
| kits/forge/apps/components/wizard/Step4Generate.tsx | Step 4: generate contract/invoice and store in session. |
| kits/forge/apps/components/wizard/Step3GoverningLaw.tsx | Step 3: call tradeoff flow + select option. |
| kits/forge/apps/components/wizard/Step2Pricing.tsx | Step 2: call pricing flow + edit line items. |
| kits/forge/apps/components/wizard/Step1ProjectDetails.tsx | Step 1: project details form persisted to session. |
| kits/forge/apps/components/preview/SignatureCanvas.tsx | Signature capture modal/canvas. |
| kits/forge/apps/components/preview/InvoiceDocument.tsx | Invoice rendering component for preview/print. |
| kits/forge/apps/components/preview/ExportButton.tsx | Export action UI (currently print-based). |
| kits/forge/apps/components/preview/ContractDocument.tsx | Contract rendering component for preview/print. |
| kits/forge/apps/components/Nav.tsx | Top navigation with logo. |
| kits/forge/apps/components/GalaxyButton.tsx | Primary CTA button component. |
| kits/forge/apps/components/ErrorState.tsx | Standard error + retry UI. |
| kits/forge/apps/components/AuroraBackground.tsx | Animated background wrapper. |
| kits/forge/apps/app/preview/invoice/page.tsx | Invoice preview page with signing/export actions. |
| kits/forge/apps/app/preview/contract/page.tsx | Contract preview page with signing/export actions. |
| kits/forge/apps/app/page.tsx | Landing page for the kit app. |
| kits/forge/apps/app/new/page.tsx | Wizard container page. |
| kits/forge/apps/app/layout.tsx | Root layout + metadata + nav. |
| kits/forge/apps/app/icon.svg | App icon asset. |
| kits/forge/apps/app/globals.css | Global styling, components, and print CSS. |
| kits/forge/apps/app/api/flow/route.ts | Server proxy route that executes Lamatic workflows via GraphQL. |
| kits/forge/apps/actions/orchestrate.ts | Server action wrapper around Lamatic SDK execution. |
| kits/forge/apps/.gitignore | App-level ignore rules. |
| kits/forge/apps/.env.example | Environment variable template. |
| kits/forge/agent.md | Kit/agent overview and operational notes. |
| kits/forge/README.md | Kit documentation: setup, flows, and usage. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 54 out of 58 changed files in this pull request and generated 16 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
What This Kit Does
Forge is a 4-flow autonomous freelance documentation agent designed to protect freelancers by automating professional contracts and invoices in under 60 seconds.
Users submit project details, and the agent triggers a multi-step AI pipeline: first, it performs a Pricing Analysis to suggest market-calibrated rates; second, it runs a Governing Law Tradeoff to recommend the best jurisdiction based on the freelancer's specific concerns (IP, payment, or disputes); and finally, it synthesizes a full 13-section Services Agreement and a matching Professional Invoice.
Both documents are rendered in a premium glassmorphic interface, support digital signatures, and can be exported as perfectly paginated, multi-page PDFs.
Providers & Prerequisites
/appsdirectory).How to Run Locally
cd kits/forge/appsnpm installcp .env.example .env.localand fill in your 4 Lamatic Flow IDs and API Keynpm run devLive Preview
Live App: https://forge-wheat-one.vercel.app/
Lamatic Flows
8738b556-9a25-41e9-9233-03091e4e375964a8c279-ef27-4632-a5ec-9ec3f752674e6e5e8e78-c89b-449e-b9ef-6090e72f05645788478d-6490-4107-afb9-470086c8a77dPR Checklist
1. Select Contribution Type
kits/<category>/<kit-name>/)bundles/<bundle-name>/)templates/<template-name>/)2. General Requirements
kebab-caseand matches the flow IDREADME.md(purpose, setup, usage)3. File Structure (Check what applies)
config.jsonpresent with valid metadata (name, description, tags, steps, author, env keys)flows/<flow-name>/(where applicable) include:config.json(Lamatic flow export)inputs.jsonmeta.jsonREADME.md.env.examplewith placeholder values only (kits only)config.jsonnode graphs (changes via Lamatic Studio export)4. Validation
npm install && npm run devworks locally (kits: UI runs; bundles/templates: flows are valid)[kit] Add <name> for <use case>)