@eventmodelers/cli 1.0.73 → 1.0.75

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (67) hide show
  1. package/README.md +15 -8
  2. package/cli.js +47 -29
  3. package/package.json +2 -2
  4. package/shared/build-kit/README.md +26 -9
  5. package/shared/build-kit/lib/local-ai-agent.js +281 -0
  6. package/shared/build-kit/lib/ralph.js +1 -1
  7. package/shared/build-kit/ralph-local-ai.js +40 -0
  8. package/shared/build-kit/realtime-agent.js +1 -1
  9. package/shared/skills/learn-eventmodelers-api/SKILL.md +4 -2
  10. package/stacks/blank/templates/.claude/skills/build-automation/SKILL.md +1 -1
  11. package/stacks/blank/templates/.claude/skills/build-state-change/SKILL.md +1 -1
  12. package/stacks/blank/templates/.claude/skills/build-state-view/SKILL.md +1 -1
  13. package/stacks/blank/templates/root/README.md +1 -1
  14. package/stacks/bridge/templates/bridge/lib/AGENT.md +1 -1
  15. package/stacks/bridge/templates/bridge/ralph-local-ai.js +43 -0
  16. package/stacks/modeling-kit/templates/kit/README.md +1 -1
  17. package/stacks/react/templates/.claude/skills/build-automation/SKILL.md +1 -1
  18. package/stacks/react/templates/.claude/skills/build-state-change/SKILL.md +1 -1
  19. package/stacks/react/templates/.claude/skills/build-state-view/SKILL.md +1 -1
  20. package/stacks/react/templates/build-kit/README.md +26 -9
  21. package/stacks/react/templates/build-kit/lib/ralph.js +1 -1
  22. package/stacks/react/templates/build-kit/ralph-local-ai.js +40 -0
  23. package/shared/build-kit/lib/ollama-agent.js +0 -147
  24. package/shared/build-kit/ralph-ollama.js +0 -40
  25. package/stacks/bridge/templates/bridge/ralph-ollama.js +0 -43
  26. package/stacks/cratis-csharp/templates/.claude/skills/_shared/cratis-conventions.md +0 -251
  27. package/stacks/cratis-csharp/templates/.claude/skills/build-automation/SKILL.md +0 -122
  28. package/stacks/cratis-csharp/templates/.claude/skills/build-automation/references/patterns.md +0 -115
  29. package/stacks/cratis-csharp/templates/.claude/skills/build-state-change/SKILL.md +0 -191
  30. package/stacks/cratis-csharp/templates/.claude/skills/build-state-change/references/patterns.md +0 -234
  31. package/stacks/cratis-csharp/templates/.claude/skills/build-state-view/SKILL.md +0 -149
  32. package/stacks/cratis-csharp/templates/.claude/skills/build-state-view/references/patterns.md +0 -166
  33. package/stacks/cratis-csharp/templates/build-kit/CLAUDE.md +0 -78
  34. package/stacks/cratis-csharp/templates/build-kit/lib/AGENT.md +0 -59
  35. package/stacks/cratis-csharp/templates/build-kit/lib/backend-prompt.md +0 -140
  36. package/stacks/cratis-csharp/templates/build-kit/lib/prompt.md +0 -126
  37. package/stacks/cratis-csharp/templates/root/.frontend/index.css +0 -29
  38. package/stacks/cratis-csharp/templates/root/.frontend/index.html +0 -17
  39. package/stacks/cratis-csharp/templates/root/.frontend/main.tsx +0 -18
  40. package/stacks/cratis-csharp/templates/root/.frontend/tsconfig.json +0 -42
  41. package/stacks/cratis-csharp/templates/root/.frontend/tsconfig.node.json +0 -11
  42. package/stacks/cratis-csharp/templates/root/.frontend/vite.config.ts +0 -56
  43. package/stacks/cratis-csharp/templates/root/App.tsx +0 -23
  44. package/stacks/cratis-csharp/templates/root/CratisApp.csproj +0 -25
  45. package/stacks/cratis-csharp/templates/root/CratisApp.sln +0 -18
  46. package/stacks/cratis-csharp/templates/root/GlobalUsings.cs +0 -3
  47. package/stacks/cratis-csharp/templates/root/Home.tsx +0 -102
  48. package/stacks/cratis-csharp/templates/root/Program.cs +0 -26
  49. package/stacks/cratis-csharp/templates/root/README.md +0 -192
  50. package/stacks/cratis-csharp/templates/root/SomeModule/SomeFeature/Listing/AllListings.ts +0 -47
  51. package/stacks/cratis-csharp/templates/root/SomeModule/SomeFeature/Listing/Listing.cs +0 -11
  52. package/stacks/cratis-csharp/templates/root/SomeModule/SomeFeature/Listing/Listing.ts +0 -12
  53. package/stacks/cratis-csharp/templates/root/SomeModule/SomeFeature/Listing/ListingDataTable.tsx +0 -17
  54. package/stacks/cratis-csharp/templates/root/SomeModule/SomeFeature/Listing/index.ts +0 -1
  55. package/stacks/cratis-csharp/templates/root/SomeModule/SomeFeature/Registration/Register.ts +0 -51
  56. package/stacks/cratis-csharp/templates/root/SomeModule/SomeFeature/Registration/RegisterDialog.tsx +0 -18
  57. package/stacks/cratis-csharp/templates/root/SomeModule/SomeFeature/Registration/Registration.cs +0 -27
  58. package/stacks/cratis-csharp/templates/root/SomeModule/SomeFeature/Registration/index.ts +0 -1
  59. package/stacks/cratis-csharp/templates/root/SomeModule/SomeFeature/SomeFeature.tsx +0 -22
  60. package/stacks/cratis-csharp/templates/root/SomeModule/SomeFeature/SomeName.cs +0 -3
  61. package/stacks/cratis-csharp/templates/root/SomeModule/SomeFeature/index.ts +0 -1
  62. package/stacks/cratis-csharp/templates/root/appsettings.Development.json +0 -9
  63. package/stacks/cratis-csharp/templates/root/appsettings.json +0 -26
  64. package/stacks/cratis-csharp/templates/root/docker-compose.yml +0 -23
  65. package/stacks/cratis-csharp/templates/root/package.json +0 -33
  66. package/stacks/cratis-csharp/templates/root/tsconfig.json +0 -3
  67. package/stacks/react/templates/build-kit/ralph-ollama.js +0 -40
@@ -1,18 +0,0 @@
1
- import { CommandDialog } from '@cratis/components/CommandDialog';
2
- import { InputTextField } from '@cratis/components/CommandForm';
3
- import { Register } from './Register';
4
-
5
- export const RegisterDialog = () => {
6
- return (
7
- <CommandDialog
8
- command={Register}
9
- title='Register'
10
- okLabel='Register'
11
- cancelLabel='Cancel'>
12
- <InputTextField<Register>
13
- value={c => c.name}
14
- title='Name'
15
- icon={<i className='pi pi-pencil' />} />
16
- </CommandDialog>
17
- );
18
- }
@@ -1,27 +0,0 @@
1
- namespace CratisApp.SomeModule.SomeFeature.Registration;
2
-
3
- [Command]
4
- public record Register(SomeName Name)
5
- {
6
- public (Guid, Registered) Handle()
7
- {
8
- var eventSourceId = Guid.NewGuid();
9
-
10
- return (eventSourceId, new(Name));
11
- }
12
- }
13
-
14
- [EventType]
15
- public record Registered(SomeName Name);
16
-
17
- public partial class RegistrationReactor(ILogger<RegistrationReactor> logger) : IReactor
18
- {
19
- public Task Handle(Registered evt)
20
- {
21
- LogRegistered(evt.Name);
22
- return Task.CompletedTask;
23
- }
24
-
25
- [LoggerMessage(LogLevel.Information, "Registered: {Name}")]
26
- partial void LogRegistered(string name);
27
- }
@@ -1 +0,0 @@
1
- export * from './RegisterDialog';
@@ -1,22 +0,0 @@
1
- import { Button } from 'primereact/button';
2
- import { RegisterDialog } from './Registration';
3
- import { ListingDataTable } from './Listing';
4
- import { useDialog } from '@cratis/arc.react/dialogs';
5
-
6
- export const SomeFeature = () => {
7
- const [RegistrationDialog, showRegistrationDialog] = useDialog(RegisterDialog);
8
-
9
- return (
10
- <div className='p-4'>
11
- <div className='flex justify-between items-center mb-4'>
12
- <h1 className='text-2xl font-bold'>SomeFeature</h1>
13
- <Button
14
- label='Register'
15
- icon='pi pi-plus'
16
- onClick={() => showRegistrationDialog()} />
17
- </div>
18
- <ListingDataTable />
19
- <RegistrationDialog />
20
- </div>
21
- );
22
- };
@@ -1,3 +0,0 @@
1
- namespace CratisApp.SomeModule.SomeFeature;
2
-
3
- public record SomeName(string Value) : ConceptAs<string>(Value);
@@ -1 +0,0 @@
1
- export * from './SomeFeature';
@@ -1,9 +0,0 @@
1
- {
2
- "Logging": {
3
- "LogLevel": {
4
- "Default": "Debug",
5
- "System": "Information",
6
- "Microsoft": "Information"
7
- }
8
- }
9
- }
@@ -1,26 +0,0 @@
1
- {
2
- "Logging": {
3
- "LogLevel": {
4
- "Default": "Information",
5
- "Microsoft.AspNetCore": "Warning"
6
- }
7
- },
8
- "AllowedHosts": "*",
9
- "Cratis": {
10
- "Arc": {
11
- "GeneratedApis": {
12
- "RoutePrefix": "api",
13
- "IncludeCommandNameInRoute": false,
14
- "SegmentsToSkipForRoute": 1
15
- }
16
- },
17
- "Chronicle": {
18
- "EventStore": "CratisApp",
19
- "ConnectionString": "chronicle://chronicle-dev-client:chronicle-dev-secret@localhost:35000"
20
- },
21
- "MongoDB": {
22
- "Server": "mongodb://localhost:27017",
23
- "Database": "CratisApp"
24
- }
25
- }
26
- }
@@ -1,23 +0,0 @@
1
- services:
2
- chronicle:
3
- image: cratis/chronicle:latest-development
4
- pull_policy: always
5
- environment:
6
- - OTEL_EXPORTER_OTLP_ENDPOINT=http://aspire-dashboard:18889
7
- ports:
8
- - 27017:27017
9
- - 8080:8080
10
- - 11111:11111
11
- - 30000:30000
12
- - 35000:35000
13
-
14
- aspire-dashboard:
15
- image: mcr.microsoft.com/dotnet/aspire-dashboard:latest
16
- environment:
17
- - DOTNET_DASHBOARD_UNSECURED_ALLOW_ANONYMOUS=true
18
- - DOTNET_DASHBOARD_OTLP_ENDPOINT_URL=http://chronicle:18889
19
- - ALLOW_UNSECURED_TRANSPORT=true
20
- - DOTNET_ENVIRONMENT=Development
21
- ports:
22
- - 18888:18888
23
- - 4317:18889
@@ -1,33 +0,0 @@
1
- {
2
- "name": "cratisapp",
3
- "private": true,
4
- "version": "0.0.0",
5
- "type": "module",
6
- "scripts": {
7
- "dev": "vite --config .frontend/vite.config.ts",
8
- "build": "tsc -b .frontend/tsconfig.json && vite build --config .frontend/vite.config.ts",
9
- "preview": "vite preview --config .frontend/vite.config.ts"
10
- },
11
- "dependencies": {
12
- "@cratis/arc.react": "^20.3.1",
13
- "@cratis/arc.vite": "^20.3.1",
14
- "@cratis/components": "^2.5.0",
15
- "primeicons": "^7.0.0",
16
- "primereact": "^10.9.7",
17
- "react": "^19.0.0",
18
- "react-dom": "^19.0.0",
19
- "react-icons": "^5.5.0",
20
- "react-router-dom": "^7.0.0",
21
- "ts-deepmerge": "^7.0.0",
22
- "usehooks-ts": "^3.1.0"
23
- },
24
- "devDependencies": {
25
- "@tailwindcss/vite": "^4.0.0",
26
- "@types/react": "^19.0.0",
27
- "@types/react-dom": "^19.0.0",
28
- "@vitejs/plugin-react": "^4.0.0",
29
- "tailwindcss": "^4.0.0",
30
- "typescript": "^5.5.0",
31
- "vite": "^6.0.0"
32
- }
33
- }
@@ -1,3 +0,0 @@
1
- {
2
- "extends": "./.frontend/tsconfig.json"
3
- }
@@ -1,40 +0,0 @@
1
- #!/usr/bin/env node
2
- // Ralph loop + board poller using a local Ollama model as the executor.
3
- // Run `ollama serve` first.
4
- // Usage: node ralph-ollama.js [project_dir]
5
- // OLLAMA_MODEL=qwen3.5:9b node ralph-ollama.js
6
- // OLLAMA_URL=http://host:11434 node ralph-ollama.js
7
-
8
- import { startRalph } from './lib/ralph.js';
9
- import { spawn } from 'child_process';
10
- import { dirname, join, resolve } from 'path';
11
- import { fileURLToPath } from 'url';
12
-
13
- const kitDir = dirname(fileURLToPath(import.meta.url));
14
- const projectDir = process.argv[2] ? resolve(process.argv[2]) : resolve(kitDir, '..');
15
- const model = process.env.OLLAMA_MODEL || 'qwen3.5:9b';
16
-
17
- console.log(`[ralph-ollama] model=${model}`);
18
-
19
- function runOllama() {
20
- return new Promise((resolve, reject) => {
21
- const proc = spawn('node', [join(kitDir, 'lib', 'ollama-agent.js'), model], {
22
- cwd: projectDir,
23
- stdio: 'inherit',
24
- env: process.env,
25
- });
26
- proc.on('close', (code) => (code === 0 ? resolve() : reject(new Error(`ollama-agent exited ${code}`))));
27
- proc.on('error', reject);
28
- });
29
- }
30
-
31
- startRalph({
32
- kitDir,
33
- projectDir,
34
- onTask: runOllama,
35
- // onPlannedSlice omitted — ollama-agent manages its own task queue
36
- localOnly: process.env.RALPH_LOCAL === '1',
37
- }).catch((err) => {
38
- console.error('[ralph] Fatal:', err);
39
- process.exit(1);
40
- });