feat: Add production-bottleneck-brief kit#280
Conversation
|
Failure recorded at 2026-07-20T20:34:48Z UTC. If this PR is not fixed within 4 weeks it will be automatically closed. |
|
Important Review skippedNo new commits to review since the last review. ⚙️ Run configurationConfiguration used: Repository UI (base), Organization UI (inherited) Review profile: ASSERTIVE Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
WalkthroughChangesThe kit adds deterministic order-risk calculations, two Lamatic workflows for brief generation and order Q&A, a Next.js interface, runtime configuration, styling, environment examples, and documentation. Production Bottleneck Brief
Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
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.
Actionable comments posted: 7
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@kits/production-bottleneck-brief/apps/actions/orchestrate.ts`:
- Around line 30-41: Replace the direct BRIEF_FLOW_ID and QA_FLOW_ID environment
lookups in getBottleneckBrief and askAboutOrder with the corresponding step
definitions from ../../lamatic.config. Import the central lamatic configuration
and derive each flow ID from its step’s envKey before calling
lamatic.executeFlow.
In `@kits/production-bottleneck-brief/apps/app/globals.css`:
- Around line 1-377: Replace the custom rules in globals.css with Tailwind CSS
v4 utilities and shadcn/ui component styling across the affected UI, removing
bespoke layout, typography, form, button, card, table, badge, responsive, and
animation declarations. Update the corresponding components to use shadcn/ui
primitives and Tailwind class names while preserving the existing structure,
responsive behavior, states, and visual hierarchy.
In `@kits/production-bottleneck-brief/apps/app/page.tsx`:
- Around line 136-146: Refactor the form containing the orderId and question
inputs to use react-hook-form with a zod schema and validation, replacing the
raw input elements with the project’s shadcn/ui form and input components.
Update submission and handleQuestionKeyDown to use the form API while preserving
the existing order-question behavior, and use lucide-react icons where the form
UI currently needs icons.
In `@kits/production-bottleneck-brief/constitutions/default.md`:
- Around line 1-17: Fix the MD022 heading-spacing issue in the template or
source generator that produces default.md, rather than editing this generated
file directly. Ensure generated Constitution headings have blank lines before
and after them, and preserve the existing content and formatting otherwise.
In
`@kits/production-bottleneck-brief/prompts/production-bottleneck-brief_llmnode-303_system_0.md`:
- Around line 1-13: Update the repository-level markdownlint configuration to
ignore kits/production-bottleneck-brief/prompts/**/*.md, covering the anchor
file at lines 1-13 and sibling files
kits/production-bottleneck-brief/prompts/production-bottleneck-brief_llmnode-303_user_1.md
lines 1-1 and
kits/production-bottleneck-brief/prompts/follow-up-qa_llmnode-222_system_0.md
lines 1-5; make no direct changes to any prompt content.
In `@kits/production-bottleneck-brief/README.md`:
- Line 99: Normalize trailing newlines in
kits/production-bottleneck-brief/README.md at lines 99-99 and
kits/production-bottleneck-brief/agent.md at lines 27-27 by ensuring each
Markdown file ends with exactly one newline.
- Around line 26-44: The README currently conflates the flow API payload with
the pasted UI input format. Update the documentation around the orders schema
and Order Q&A input to explicitly state that the UI accepts a bare orders array,
while the flow API receives `{ orders: [...] }` and the Q&A API additionally
requires `orderId` and `question`; keep the formats clearly distinguished and
consistent with `apps/actions/orchestrate.ts`.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI (base), Organization UI (inherited)
Review profile: ASSERTIVE
Plan: Pro
Run ID: 5a0f45a8-e205-42c5-9db6-db21326b9fe2
⛔ Files ignored due to path filters (7)
kits/production-bottleneck-brief/apps/app/favicon.icois excluded by!**/*.icokits/production-bottleneck-brief/apps/package-lock.jsonis excluded by!**/package-lock.jsonkits/production-bottleneck-brief/apps/public/file.svgis excluded by!**/*.svgkits/production-bottleneck-brief/apps/public/globe.svgis excluded by!**/*.svgkits/production-bottleneck-brief/apps/public/next.svgis excluded by!**/*.svgkits/production-bottleneck-brief/apps/public/vercel.svgis excluded by!**/*.svgkits/production-bottleneck-brief/apps/public/window.svgis excluded by!**/*.svg
📒 Files selected for processing (28)
kits/production-bottleneck-brief/.gitignorekits/production-bottleneck-brief/README.mdkits/production-bottleneck-brief/agent.mdkits/production-bottleneck-brief/apps/.env.examplekits/production-bottleneck-brief/apps/.gitignorekits/production-bottleneck-brief/apps/AGENTS.mdkits/production-bottleneck-brief/apps/CLAUDE.mdkits/production-bottleneck-brief/apps/README.mdkits/production-bottleneck-brief/apps/actions/orchestrate.tskits/production-bottleneck-brief/apps/app/globals.csskits/production-bottleneck-brief/apps/app/layout.tsxkits/production-bottleneck-brief/apps/app/page.tsxkits/production-bottleneck-brief/apps/eslint.config.mjskits/production-bottleneck-brief/apps/lib/lamatic-client.tskits/production-bottleneck-brief/apps/next.config.tskits/production-bottleneck-brief/apps/package.jsonkits/production-bottleneck-brief/apps/postcss.config.mjskits/production-bottleneck-brief/apps/tsconfig.jsonkits/production-bottleneck-brief/constitutions/default.mdkits/production-bottleneck-brief/flows/follow-up-qa.tskits/production-bottleneck-brief/flows/production-bottleneck-brief.tskits/production-bottleneck-brief/lamatic.config.tskits/production-bottleneck-brief/model-configs/follow-up-qa_llmnode-222_generative-model-name.tskits/production-bottleneck-brief/model-configs/production-bottleneck-brief_llmnode-303_generative-model-name.tskits/production-bottleneck-brief/prompts/follow-up-qa_llmnode-222_system_0.mdkits/production-bottleneck-brief/prompts/follow-up-qa_llmnode-222_user_1.mdkits/production-bottleneck-brief/prompts/production-bottleneck-brief_llmnode-303_system_0.mdkits/production-bottleneck-brief/prompts/production-bottleneck-brief_llmnode-303_user_1.md
:robot_face: AgentKit Structural ValidationNew Contributions Detected
Check Results
🎉 All checks passed! This contribution follows the AgentKit structure. |
|
/validate |
|
📡 Running Studio validation — results will appear here shortly. |
Studio Runtime Validation (Phase 2)✅ Studio validation passed. The kit loaded successfully in Lamatic Studio. This PR is ready for final review and merge. |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@kits/production-bottleneck-brief/scripts/follow-up-qa_code-node-797_code.ts`:
- Around line 4-12: Update computeStats in
kits/production-bottleneck-brief/scripts/follow-up-qa_code-node-797_code.ts
(lines 4-12) and the corresponding date/stat calculations in
kits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts
(lines 4-13) to subtract numeric date timestamps rather than Date objects. Guard
quantity before calculating pctComplete so zero, invalid, or missing quantities
produce a safe non-Infinity/non-NaN result while preserving valid percentage
calculations.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI (base), Organization UI (inherited)
Review profile: ASSERTIVE
Plan: Pro
Run ID: 8f32995c-bfc0-47c1-b6ae-04f21d8bfb67
📒 Files selected for processing (2)
kits/production-bottleneck-brief/scripts/follow-up-qa_code-node-797_code.tskits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
kits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts (1)
13-24: 🎯 Functional Correctness | 🟠 Major | ⚡ Quick winNeutralize the rogue multiplier.
Agent, your mission, should you choose to accept it, is to intercept a critical data corruption threat in our completion stats.
By applying the
* 100multiplier on line 13,pctCompleteis successfully scaled to a percentage. However, the asset at line 24 still multiplies it by 100 again. This double-scaling will cause a 50% completion rate to be reported as 5000, severely compromising our situational awareness.Disarm the second multiplier to restore data integrity. This message will self-destruct.
🕵️ Proposed mission parameters (Fix)
- const pctComplete = quantity > 0 ? Math.round((completedQuantity / quantity) * 100) : 0; + const pctComplete = quantity > 0 ? Math.round((completedQuantity / quantity) * 100) : 0; const stageIndex = o.stages.indexOf(o.currentStage); const stagesRemaining = o.stages.length - stageIndex - 1; const atRisk = daysUntilDue < (stagesRemaining * 3) || (daysUntilDue < 0); return { id: o.id, currentStage: o.currentStage, daysInStage, daysUntilDue, - pctComplete: Math.round(pctComplete * 100), + pctComplete, stagesRemaining, atRisk };🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@kits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts` around lines 13 - 24, Remove the redundant percentage multiplier from the pctComplete field in the returned object. Keep the existing calculation in the pctComplete declaration so completion values remain correctly scaled once.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Outside diff comments:
In
`@kits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts`:
- Around line 13-24: Remove the redundant percentage multiplier from the
pctComplete field in the returned object. Keep the existing calculation in the
pctComplete declaration so completion values remain correctly scaled once.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI (base), Organization UI (inherited)
Review profile: ASSERTIVE
Plan: Pro
Run ID: 7880856f-e05e-4dc9-9559-2019318c60aa
📒 Files selected for processing (2)
kits/production-bottleneck-brief/scripts/follow-up-qa_code-node-797_code.tskits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts
|
/validate |
|
📡 Running Studio validation — results will appear here shortly. |
|
Status update — everything actionable on my end for this PR is done. Fixes for issues flagged by GitHub Actions (structural/Phase 2 validation):
Fixes for issues flagged by CodeRabbit:
Two things still pending that look like infra-side issues rather than anything
Happy to make any further changes needed — otherwise I'll keep an eye out for |
|
Hey @akshatvirmani I just wanna flag that I have few more ideas for my kit (to add more features/capabilities to my current flows used in the kit). But I'll hold off on any of that until this PR gets merged (cause this is already at "passing-checks" label and making changes will might affect that). Therefore I'll open that as a separate follow-up PR at that point rather than adding scope here, to make sure there won't be any confusion with PRs and merging. |
|
@coderabbitai review |
✅ Action performedReview finished.
|
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (2)
kits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts (2)
1-1: 🎯 Functional Correctness | 🟠 Major | ⚡ Quick winMission: read
ordersfrom the Code-node runtime.Line 1’s mustache expression resolves to a literal path inside a Code node, so
computeStatswill not receive the order array. Readworkflow.triggerNode_1.output.ordersinstead.Based on learnings, Code-node bodies must access upstream values through
workflow.<nodeId>.output.<field>, not{{...}}.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@kits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts` at line 1, Replace the mustache-based orders assignment with a Code-node runtime access through workflow.triggerNode_1.output.orders, ensuring computeStats receives the upstream order array.Source: Learnings
5-27: 🩺 Stability & Availability | 🟠 Major | ⚡ Quick winMission: make malformed-order handling safe and contract-compatible.
Line 6 dereferences
obefore validation, so anullarray entry crashes the entire flow rather than being flagged at risk. The invalid-data return also omits metrics required byOrderStatand rendered by the app. Guard non-object entries before property access, then return a complete sentinel stat or exclude invalid records fromstats.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@kits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts` around lines 5 - 27, Update the order mapping logic around the `orders.map` callback to guard null or non-object entries before accessing fields such as `stageEnteredDate` and `dueDate`. For invalid entries, return a complete sentinel `OrderStat` containing all metrics required by the contract and renderer while preserving `atRisk: true`, or exclude them from `stats` if that is the established contract; do not allow malformed records to crash the flow.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Outside diff comments:
In
`@kits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts`:
- Line 1: Replace the mustache-based orders assignment with a Code-node runtime
access through workflow.triggerNode_1.output.orders, ensuring computeStats
receives the upstream order array.
- Around line 5-27: Update the order mapping logic around the `orders.map`
callback to guard null or non-object entries before accessing fields such as
`stageEnteredDate` and `dueDate`. For invalid entries, return a complete
sentinel `OrderStat` containing all metrics required by the contract and
renderer while preserving `atRisk: true`, or exclude them from `stats` if that
is the established contract; do not allow malformed records to crash the flow.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI (base), Organization UI (inherited)
Review profile: ASSERTIVE
Plan: Pro
Run ID: 382402f8-0509-443e-b312-ab1741d2a6c6
📒 Files selected for processing (2)
kits/production-bottleneck-brief/.env.examplekits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts
Updated the live demo link in the README.
|
/validate |
|
📡 Running Studio validation — results will appear here shortly. |
|
LGTM! Can you please resolve two comments left by coderabbit? @IbrahimKhan7208 |
Add validation for order data in computeStats function.
|
@coderabbitai review |
✅ Action performedReview finished.
|
There was a problem hiding this comment.
Actionable comments posted: 4
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
kits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts (1)
1-1: 🩺 Stability & Availability | 🟡 Minor | ⚡ Quick winMission continues with the repository’s binding rule.
The repository guidelines for
kits/*/scripts/*.tsrequire externalizing Code node values with Lamatic template variables, and these literal mustache inputs remain in code-node scripts. UpdateproductsandorderIdthrough the required template binding form instead of leaving the mustache expressions embedded in the generated.tsfiles.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@kits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts` at line 1, Replace the embedded mustache inputs with the repository-required Lamatic template variable binding for products and orderId. Apply the corresponding updates in kits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts lines 1-1 and kits/production-bottleneck-brief/scripts/follow-up-qa_code-node-797_code.ts lines 1-2, preserving the existing variable usage while externalizing their values.Source: Learnings
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@kits/production-bottleneck-brief/apps/app/globals.css`:
- Around line 537-552: Merge the two consecutive .chat-thread CSS rule blocks
into a single rule, preserving all existing layout, spacing, background, border,
and radius declarations without changing their values.
In `@kits/production-bottleneck-brief/flows/follow-up-qa.ts`:
- Around line 165-174: Update the second memoryValue entry in the follow-up QA
flow so the generated response from LLMNode_222 is stored with role "assistant"
rather than "user"; leave the question entry and content unchanged.
In
`@kits/production-bottleneck-brief/prompts/follow-up-qa_llmnode-222_system_0.md`:
- Around line 4-10: Remove the “deprioritizing this order behind one with more
remaining slack” example from the recovery-action guidance. Keep only actions
grounded in the available single-order stats, such as reallocating resources to
the current bottleneck or escalating a stage-specific supplier, and preserve the
prohibition against assuming unavailable information.
In
`@kits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts`:
- Around line 22-28: Update the validators in
kits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts
lines 22-28 and
kits/production-bottleneck-brief/scripts/follow-up-qa_code-node-797_code.ts
lines 13-19 to require completedQuantity <= quantity alongside the existing
finite and non-negative checks. Apply the same upper-bound validation in both
calculator paths.
---
Outside diff comments:
In
`@kits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts`:
- Line 1: Replace the embedded mustache inputs with the repository-required
Lamatic template variable binding for products and orderId. Apply the
corresponding updates in
kits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts
lines 1-1 and
kits/production-bottleneck-brief/scripts/follow-up-qa_code-node-797_code.ts
lines 1-2, preserving the existing variable usage while externalizing their
values.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI (base), Organization UI (inherited)
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: ffe7cb51-12fa-4b0c-b810-74335c652d01
📒 Files selected for processing (21)
kits/production-bottleneck-brief/.env.examplekits/production-bottleneck-brief/README.mdkits/production-bottleneck-brief/agent.mdkits/production-bottleneck-brief/apps/actions/orchestrate.tskits/production-bottleneck-brief/apps/app/globals.csskits/production-bottleneck-brief/apps/app/layout.tsxkits/production-bottleneck-brief/apps/app/page.tsxkits/production-bottleneck-brief/flows/follow-up-qa.tskits/production-bottleneck-brief/flows/production-bottleneck-brief.tskits/production-bottleneck-brief/lamatic.config.tskits/production-bottleneck-brief/model-configs/follow-up-qa_memory-node-268_embedding-model-name.tskits/production-bottleneck-brief/model-configs/follow-up-qa_memory-node-268_generative-model-name.tskits/production-bottleneck-brief/model-configs/follow-up-qa_memory-retrieve-node-644_embedding-model-name.tskits/production-bottleneck-brief/model-configs/production-bottleneck-brief_llmnode-430_generative-model-name.tskits/production-bottleneck-brief/prompts/follow-up-qa_llmnode-222_system_0.mdkits/production-bottleneck-brief/prompts/follow-up-qa_llmnode-222_user_1.mdkits/production-bottleneck-brief/prompts/production-bottleneck-brief_llmnode-303_system_0.mdkits/production-bottleneck-brief/prompts/production-bottleneck-brief_llmnode-430_system_0.mdkits/production-bottleneck-brief/prompts/production-bottleneck-brief_llmnode-430_user_1.mdkits/production-bottleneck-brief/scripts/follow-up-qa_code-node-797_code.tskits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts
…tion validation, prompt scope, duplicate CSS selector
…/IbrahimKhan7208/AgentKit into feat/production-bottleneck-brief
|
@coderabbitai review |
✅ Action performedReview finished.
|
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In
`@kits/production-bottleneck-brief/prompts/follow-up-qa_llmnode-222_system_0.md`:
- Around line 4-9: Remove the “escalating to a supplier” example from the
recovery-action guidance in the prompt. Keep the instruction limited to concrete
actions supported by the available order statistics, such as reallocating
resources to the current bottleneck, without requiring unavailable supplier or
contact information.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI (base), Organization UI (inherited)
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: 054699a3-046d-4a9d-9980-625ec8e921c5
📒 Files selected for processing (5)
kits/production-bottleneck-brief/apps/app/globals.csskits/production-bottleneck-brief/flows/follow-up-qa.tskits/production-bottleneck-brief/prompts/follow-up-qa_llmnode-222_system_0.mdkits/production-bottleneck-brief/scripts/follow-up-qa_code-node-797_code.tskits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.ts
|
@akshatvirmani All CodeRabbit comments from the latest reviews are resolved, Let me know if anything else needs attention. |
|
Hi @IbrahimKhan7208! 👋 Before this PR can be reviewed by maintainers, please resolve all comments and requested changes from the CodeRabbit automated review. Steps to follow:
This helps keep the review process efficient for everyone. Thank you! 🙏 |
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
Hey @akshatvirmani , are we good now? all the comments from coderabbit is finally resolved, in the last time few comments were there that's why github-action bot gave me the message and right know I finally resolved all, and coderabbit has approved all. can you just make github-action bot to re asses and attach the "passing-check" label again and we can move forward I think? |
What this is
A kit that turns production order data (stage, timeline, quantity) into a prioritized, plain-English brief on which orders are at risk of missing their deadline — plus a follow-up Q&A flow for asking about any specific flagged order.
Live Demo
Design decision
Risk detection (days until due, days in stage, % complete, overdue status) is computed deterministically in a code node — not by the LLM. The LLM's only job is synthesizing those precomputed stats into a prioritized narrative, translating raw values into plain language. This keeps output reliable and reproducible rather than leaving risk assessment to model judgment.
Note on PR checklist format
This repo's auto-filled PR template references an older structure (
config.json,bundles/<bundle-name>/, per-flowmeta.json/inputs.json). I followed the currentCONTRIBUTING.mdinstead, which useslamatic.config.ts+ flat.tsfiles underflows/— matching the structure of existing merged kits likecontent-generationandarticle-summariser. Checklist below reflects CONTRIBUTING.md's actual requirements.Checklist (per CONTRIBUTING.md)
kits/production-bottleneck-brief/(kebab-case, unique)lamatic.config.tspresent with validtype,name,author,tags,steps,linksagent.mdpresentREADME.mdpresent, describes purpose, setup, and usageflows/<name>.tsexists for every step inlamatic.config.tsconstitutions/default.mdpresent.env.examplepresent with placeholder values onlyapps/package.jsonworks withnpm install && npm run devlinks.githubpoints tokits/production-bottleneck-brieflinks.deployhasroot-directory=kits/production-bottleneck-brief/apps.envor.env.localcommitted@referencepaths resolvekits/production-bottleneck-brief/Agentkit Challenge
Submitting as part of the Applied AI Engineer internship assignment.
Added
kits/production-bottleneck-brief/kit contents:kits/production-bottleneck-brief/.env.examplekits/production-bottleneck-brief/.gitignorekits/production-bottleneck-brief/README.mdkits/production-bottleneck-brief/agent.mdkits/production-bottleneck-brief/constitutions/default.mdkits/production-bottleneck-brief/lamatic.config.tskits/production-bottleneck-brief/flows/production-bottleneck-brief.tskits/production-bottleneck-brief/flows/follow-up-qa.tskits/production-bottleneck-brief/scripts/production-bottleneck-brief_code-node-969_code.tskits/production-bottleneck-brief/scripts/follow-up-qa_code-node-797_code.tskits/production-bottleneck-brief/prompts/production-bottleneck-brief_llmnode-303_system_0.mdkits/production-bottleneck-brief/prompts/production-bottleneck-brief_llmnode-303_user_1.mdkits/production-bottleneck-brief/prompts/production-bottleneck-brief_llmnode-430_system_0.mdkits/production-bottleneck-brief/prompts/production-bottleneck-brief_llmnode-430_user_1.mdkits/production-bottleneck-brief/prompts/follow-up-qa_llmnode-222_system_0.mdkits/production-bottleneck-brief/prompts/follow-up-qa_llmnode-222_user_1.mdkits/production-bottleneck-brief/model-configs/production-bottleneck-brief_llmnode-303_generative-model-name.tskits/production-bottleneck-brief/model-configs/production-bottleneck-brief_llmnode-430_generative-model-name.tskits/production-bottleneck-brief/model-configs/follow-up-qa_llmnode-222_generative-model-name.tskits/production-bottleneck-brief/model-configs/follow-up-qa_memory-node-268_embedding-model-name.tskits/production-bottleneck-brief/model-configs/follow-up-qa_memory-node-268_generative-model-name.tskits/production-bottleneck-brief/model-configs/follow-up-qa_memory-retrieve-node-644_embedding-model-name.tsAdded Next.js demo app under
kits/production-bottleneck-brief/apps/:kits/production-bottleneck-brief/apps/.env.examplekits/production-bottleneck-brief/apps/.gitignorekits/production-bottleneck-brief/apps/AGENTS.mdkits/production-bottleneck-brief/apps/CLAUDE.mdkits/production-bottleneck-brief/apps/README.mdkits/production-bottleneck-brief/apps/actions/orchestrate.tskits/production-bottleneck-brief/apps/app/favicon.icokits/production-bottleneck-brief/apps/app/globals.csskits/production-bottleneck-brief/apps/app/layout.tsxkits/production-bottleneck-brief/apps/app/page.tsxkits/production-bottleneck-brief/apps/eslint.config.mjskits/production-bottleneck-brief/apps/lib/lamatic-client.tskits/production-bottleneck-brief/apps/next.config.tskits/production-bottleneck-brief/apps/package.jsonkits/production-bottleneck-brief/apps/package-lock.jsonkits/production-bottleneck-brief/apps/postcss.config.mjskits/production-bottleneck-brief/apps/tsconfig.jsonkits/production-bottleneck-brief/apps/public/file.svgkits/production-bottleneck-brief/apps/public/globe.svgkits/production-bottleneck-brief/apps/public/next.svgkits/production-bottleneck-brief/apps/public/vercel.svgkits/production-bottleneck-brief/apps/public/window.svgFlow node types introduced (from
kits/production-bottleneck-brief/flows/*.ts; no separateflow.jsonfile present):triggerNodedynamicNode(used for code, LLM, and memory retrieve/add via the specificnodeId)responseNoderesponseEdgeplus standard flow wiring between nodesHigh-level flow behavior:
production-bottleneck-brieftriggerNodeacceptsorders[]dynamicNodecode computes deterministic per-order stats (e.g., days until due, days in stage, % complete, at-risk/overdue)dynamicNodeLLM generates a prioritized plain-English bottleneck brief from those computed statsdynamicNodeLLM turns the brief into an internal “email draft”responseNodereturns{ brief, stats, emailDraft }follow-up-qatriggerNodeacceptsorders[],orderId, andquestiondynamicNodecode computes stats for the matched order (or returns an error payload)dynamicNodememory retrieve searchesorderQaHistorybyorderIdand uses the question as the search querydynamicNodeLLM answers using the order stats + retrieved memorydynamicNodememory add stores the user question and assistant answer back intoorderQaHistoryresponseNodereturns the generated answer