@codexa/cli 8.6.0 → 8.6.9
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.
- package/commands/architect.ts +760 -760
- package/commands/check.ts +131 -131
- package/commands/clear.ts +170 -170
- package/commands/decide.ts +249 -249
- package/commands/discover.ts +1071 -1071
- package/commands/knowledge.ts +361 -361
- package/commands/patterns.ts +621 -621
- package/commands/plan.ts +376 -376
- package/commands/product.ts +626 -626
- package/commands/research.ts +754 -754
- package/commands/review.ts +463 -463
- package/commands/standards.ts +200 -200
- package/commands/task.ts +623 -623
- package/commands/utils.ts +1021 -1021
- package/db/connection.ts +32 -32
- package/db/schema.ts +719 -719
- package/detectors/README.md +109 -109
- package/detectors/dotnet.ts +357 -357
- package/detectors/flutter.ts +350 -350
- package/detectors/go.ts +324 -324
- package/detectors/index.ts +387 -387
- package/detectors/jvm.ts +433 -433
- package/detectors/loader.ts +128 -128
- package/detectors/node.ts +493 -493
- package/detectors/python.ts +423 -423
- package/detectors/rust.ts +348 -348
- package/gates/standards-validator.ts +204 -204
- package/gates/validator.ts +441 -441
- package/package.json +44 -43
- package/protocol/process-return.ts +450 -450
- package/protocol/subagent-protocol.ts +401 -401
- package/workflow.ts +783 -782
package/detectors/README.md
CHANGED
|
@@ -1,110 +1,110 @@
|
|
|
1
|
-
# Universal Stack Detection System
|
|
2
|
-
|
|
3
|
-
Sistema de detecção de stack agnóstico e modular para o Codexa Workflow.
|
|
4
|
-
|
|
5
|
-
## Ecossistemas Suportados
|
|
6
|
-
|
|
7
|
-
| Ecossistema | Marcadores Principais | Tecnologias Detectadas |
|
|
8
|
-
|-------------|----------------------|------------------------|
|
|
9
|
-
| **.NET** | `*.csproj`, `*.sln`, `*.fsproj` | ASP.NET Core, Blazor, EF Core, xUnit, NUnit |
|
|
10
|
-
| **Node.js** | `package.json`, `*.lock` | Next.js, React, Vue, Express, Prisma, Drizzle |
|
|
11
|
-
| **Python** | `pyproject.toml`, `requirements.txt` | Django, FastAPI, Flask, SQLAlchemy, pytest |
|
|
12
|
-
| **Go** | `go.mod`, `go.sum` | Gin, Echo, Fiber, GORM, Ent |
|
|
13
|
-
| **Rust** | `Cargo.toml`, `Cargo.lock` | Actix, Axum, Diesel, SeaORM, Tokio |
|
|
14
|
-
| **JVM** | `pom.xml`, `build.gradle` | Spring Boot, Quarkus, Hibernate, JUnit |
|
|
15
|
-
| **Flutter** | `pubspec.yaml` | Flutter, Riverpod, Bloc, Hive |
|
|
16
|
-
|
|
17
|
-
## Arquitetura
|
|
18
|
-
|
|
19
|
-
```
|
|
20
|
-
detectors/
|
|
21
|
-
├── index.ts # Core: tipos, registro, utilities
|
|
22
|
-
├── loader.ts # Carrega todos os detectores
|
|
23
|
-
├── dotnet.ts # .NET/C#/F#
|
|
24
|
-
├── node.ts # Node.js/Bun/Deno
|
|
25
|
-
├── python.ts # Python
|
|
26
|
-
├── go.ts # Go
|
|
27
|
-
├── rust.ts # Rust
|
|
28
|
-
├── jvm.ts # Java/Kotlin/Scala
|
|
29
|
-
└── flutter.ts # Flutter/Dart
|
|
30
|
-
```
|
|
31
|
-
|
|
32
|
-
## Uso
|
|
33
|
-
|
|
34
|
-
### Detecção Completa
|
|
35
|
-
|
|
36
|
-
```typescript
|
|
37
|
-
import { detectUniversal } from "./detectors/loader";
|
|
38
|
-
|
|
39
|
-
const result = await detectUniversal();
|
|
40
|
-
|
|
41
|
-
console.log(result.primary); // { language, runtime, framework }
|
|
42
|
-
console.log(result.ecosystems); // ["dotnet", "node", ...]
|
|
43
|
-
console.log(result.stack); // { frontend, backend, database, ... }
|
|
44
|
-
console.log(result.allTechnologies); // Full details with confidence
|
|
45
|
-
```
|
|
46
|
-
|
|
47
|
-
### Compatibilidade Legacy
|
|
48
|
-
|
|
49
|
-
```typescript
|
|
50
|
-
import { detectStackLegacy } from "./detectors/loader";
|
|
51
|
-
|
|
52
|
-
const { stack, structure } = await detectStackLegacy();
|
|
53
|
-
// Returns same format as old detectStack()/detectStructure()
|
|
54
|
-
```
|
|
55
|
-
|
|
56
|
-
## Adicionando Novo Detector
|
|
57
|
-
|
|
58
|
-
```typescript
|
|
59
|
-
// detectors/myecosystem.ts
|
|
60
|
-
import { registerDetector, Detector } from "./index";
|
|
61
|
-
|
|
62
|
-
const myDetector: Detector = {
|
|
63
|
-
name: "myecosystem",
|
|
64
|
-
ecosystem: "myecosystem",
|
|
65
|
-
priority: 50,
|
|
66
|
-
markers: [
|
|
67
|
-
{ type: "file", pattern: "myconfig.json", weight: 1.0 },
|
|
68
|
-
],
|
|
69
|
-
|
|
70
|
-
async detect(cwd: string) {
|
|
71
|
-
// Detection logic
|
|
72
|
-
return {
|
|
73
|
-
ecosystem: "myecosystem",
|
|
74
|
-
technologies: [...],
|
|
75
|
-
structure: {...},
|
|
76
|
-
configFiles: [...],
|
|
77
|
-
};
|
|
78
|
-
},
|
|
79
|
-
};
|
|
80
|
-
|
|
81
|
-
registerDetector(myDetector);
|
|
82
|
-
```
|
|
83
|
-
|
|
84
|
-
Depois adicione o import em `loader.ts`:
|
|
85
|
-
|
|
86
|
-
```typescript
|
|
87
|
-
import "./myecosystem";
|
|
88
|
-
```
|
|
89
|
-
|
|
90
|
-
## Categorias de Tecnologia
|
|
91
|
-
|
|
92
|
-
- `runtime` - Linguagem/runtime (Node.js, .NET, Python)
|
|
93
|
-
- `frontend` - Frameworks frontend (Next.js, React, Flutter)
|
|
94
|
-
- `backend` - Frameworks backend (Express, ASP.NET, Django)
|
|
95
|
-
- `database` - Bancos de dados (PostgreSQL, MongoDB, Redis)
|
|
96
|
-
- `orm` - ORMs (Prisma, EF Core, SQLAlchemy)
|
|
97
|
-
- `styling` - CSS/Styling (Tailwind, Styled Components)
|
|
98
|
-
- `auth` - Autenticação (NextAuth, Firebase Auth)
|
|
99
|
-
- `testing` - Testes (Jest, pytest, xUnit)
|
|
100
|
-
- `build` - Build tools (Webpack, Gradle, Poetry)
|
|
101
|
-
- `devops` - DevOps (Docker, Prometheus)
|
|
102
|
-
|
|
103
|
-
## Confiança (Confidence)
|
|
104
|
-
|
|
105
|
-
Cada tecnologia detectada tem um score de confiança (0-1):
|
|
106
|
-
|
|
107
|
-
- **1.0**: Arquivo/configuração específica encontrada
|
|
108
|
-
- **0.9**: Dependência explícita no manifest
|
|
109
|
-
- **0.7-0.8**: Arquivos de código encontrados
|
|
1
|
+
# Universal Stack Detection System
|
|
2
|
+
|
|
3
|
+
Sistema de detecção de stack agnóstico e modular para o Codexa Workflow.
|
|
4
|
+
|
|
5
|
+
## Ecossistemas Suportados
|
|
6
|
+
|
|
7
|
+
| Ecossistema | Marcadores Principais | Tecnologias Detectadas |
|
|
8
|
+
|-------------|----------------------|------------------------|
|
|
9
|
+
| **.NET** | `*.csproj`, `*.sln`, `*.fsproj` | ASP.NET Core, Blazor, EF Core, xUnit, NUnit |
|
|
10
|
+
| **Node.js** | `package.json`, `*.lock` | Next.js, React, Vue, Express, Prisma, Drizzle |
|
|
11
|
+
| **Python** | `pyproject.toml`, `requirements.txt` | Django, FastAPI, Flask, SQLAlchemy, pytest |
|
|
12
|
+
| **Go** | `go.mod`, `go.sum` | Gin, Echo, Fiber, GORM, Ent |
|
|
13
|
+
| **Rust** | `Cargo.toml`, `Cargo.lock` | Actix, Axum, Diesel, SeaORM, Tokio |
|
|
14
|
+
| **JVM** | `pom.xml`, `build.gradle` | Spring Boot, Quarkus, Hibernate, JUnit |
|
|
15
|
+
| **Flutter** | `pubspec.yaml` | Flutter, Riverpod, Bloc, Hive |
|
|
16
|
+
|
|
17
|
+
## Arquitetura
|
|
18
|
+
|
|
19
|
+
```
|
|
20
|
+
detectors/
|
|
21
|
+
├── index.ts # Core: tipos, registro, utilities
|
|
22
|
+
├── loader.ts # Carrega todos os detectores
|
|
23
|
+
├── dotnet.ts # .NET/C#/F#
|
|
24
|
+
├── node.ts # Node.js/Bun/Deno
|
|
25
|
+
├── python.ts # Python
|
|
26
|
+
├── go.ts # Go
|
|
27
|
+
├── rust.ts # Rust
|
|
28
|
+
├── jvm.ts # Java/Kotlin/Scala
|
|
29
|
+
└── flutter.ts # Flutter/Dart
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## Uso
|
|
33
|
+
|
|
34
|
+
### Detecção Completa
|
|
35
|
+
|
|
36
|
+
```typescript
|
|
37
|
+
import { detectUniversal } from "./detectors/loader";
|
|
38
|
+
|
|
39
|
+
const result = await detectUniversal();
|
|
40
|
+
|
|
41
|
+
console.log(result.primary); // { language, runtime, framework }
|
|
42
|
+
console.log(result.ecosystems); // ["dotnet", "node", ...]
|
|
43
|
+
console.log(result.stack); // { frontend, backend, database, ... }
|
|
44
|
+
console.log(result.allTechnologies); // Full details with confidence
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
### Compatibilidade Legacy
|
|
48
|
+
|
|
49
|
+
```typescript
|
|
50
|
+
import { detectStackLegacy } from "./detectors/loader";
|
|
51
|
+
|
|
52
|
+
const { stack, structure } = await detectStackLegacy();
|
|
53
|
+
// Returns same format as old detectStack()/detectStructure()
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
## Adicionando Novo Detector
|
|
57
|
+
|
|
58
|
+
```typescript
|
|
59
|
+
// detectors/myecosystem.ts
|
|
60
|
+
import { registerDetector, Detector } from "./index";
|
|
61
|
+
|
|
62
|
+
const myDetector: Detector = {
|
|
63
|
+
name: "myecosystem",
|
|
64
|
+
ecosystem: "myecosystem",
|
|
65
|
+
priority: 50,
|
|
66
|
+
markers: [
|
|
67
|
+
{ type: "file", pattern: "myconfig.json", weight: 1.0 },
|
|
68
|
+
],
|
|
69
|
+
|
|
70
|
+
async detect(cwd: string) {
|
|
71
|
+
// Detection logic
|
|
72
|
+
return {
|
|
73
|
+
ecosystem: "myecosystem",
|
|
74
|
+
technologies: [...],
|
|
75
|
+
structure: {...},
|
|
76
|
+
configFiles: [...],
|
|
77
|
+
};
|
|
78
|
+
},
|
|
79
|
+
};
|
|
80
|
+
|
|
81
|
+
registerDetector(myDetector);
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
Depois adicione o import em `loader.ts`:
|
|
85
|
+
|
|
86
|
+
```typescript
|
|
87
|
+
import "./myecosystem";
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
## Categorias de Tecnologia
|
|
91
|
+
|
|
92
|
+
- `runtime` - Linguagem/runtime (Node.js, .NET, Python)
|
|
93
|
+
- `frontend` - Frameworks frontend (Next.js, React, Flutter)
|
|
94
|
+
- `backend` - Frameworks backend (Express, ASP.NET, Django)
|
|
95
|
+
- `database` - Bancos de dados (PostgreSQL, MongoDB, Redis)
|
|
96
|
+
- `orm` - ORMs (Prisma, EF Core, SQLAlchemy)
|
|
97
|
+
- `styling` - CSS/Styling (Tailwind, Styled Components)
|
|
98
|
+
- `auth` - Autenticação (NextAuth, Firebase Auth)
|
|
99
|
+
- `testing` - Testes (Jest, pytest, xUnit)
|
|
100
|
+
- `build` - Build tools (Webpack, Gradle, Poetry)
|
|
101
|
+
- `devops` - DevOps (Docker, Prometheus)
|
|
102
|
+
|
|
103
|
+
## Confiança (Confidence)
|
|
104
|
+
|
|
105
|
+
Cada tecnologia detectada tem um score de confiança (0-1):
|
|
106
|
+
|
|
107
|
+
- **1.0**: Arquivo/configuração específica encontrada
|
|
108
|
+
- **0.9**: Dependência explícita no manifest
|
|
109
|
+
- **0.7-0.8**: Arquivos de código encontrados
|
|
110
110
|
- **0.5-0.6**: Diretórios/estrutura inferida
|