Steps 309-319: Sprint 11 Phases 11d-e — Kotlin/C# languages + workflow annotation foundation
Phase 11d (Steps 309-313): Kotlin + C# parsers and generators - KotlinParser (regex-based): fun, suspend fun, class, data class, val/var - KotlinGenerator: idiomatic Kotlin output with type mappings - CSharpParser (regex-based): methods, async, class, interface - CSharpGenerator: Allman braces, foreach, Task async, LINQ types - Pipeline integration for both languages, 10 parsers + 10 generators Phase 11e (Steps 314-319): Workflow annotation foundation - AnnotationInference: generalized multi-subject inference engine - Subject 9 routing annotations: ContextWidth, Review, Ambiguity, Automatability, Priority, ImplementationStatus - SkeletonAST: project specification before code exists - Architect tooling: createSkeleton, addSkeletonNode, getProjectModel, inferAnnotations RPCs + 4 MCP tools (42+ total) - Inference-to-routing bridge: complexity→ambiguity, getter→deterministic - TrainingDataExporter + TrainingDataGenerator scaffolding Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -8,6 +8,7 @@
|
||||
#include "ast/Serialization.h"
|
||||
#include "ast/Annotation.h"
|
||||
#include "ast/HostBoundary.h"
|
||||
#include "ASTUtils.h"
|
||||
#include "EnvironmentSpec.h"
|
||||
#include <nlohmann/json.hpp>
|
||||
#include <string>
|
||||
@@ -321,6 +322,33 @@ inline json extractSemanticSummary(const ASTNode* node) {
|
||||
if (!da->selection.empty()) obj["selection"] = da->selection;
|
||||
if (!obj.empty()) sem["decision"] = obj;
|
||||
}
|
||||
// Subject 9: Workflow Routing (Step 315)
|
||||
else if (a->conceptType == "ContextWidthAnnotation") {
|
||||
auto* cw = static_cast<const ContextWidthAnnotation*>(a);
|
||||
if (!cw->width.empty()) sem["contextWidth"] = cw->width;
|
||||
}
|
||||
else if (a->conceptType == "ReviewAnnotation") {
|
||||
auto* ra = static_cast<const ReviewAnnotation*>(a);
|
||||
json obj;
|
||||
obj["required"] = ra->required;
|
||||
if (!ra->reviewer.empty()) obj["reviewer"] = ra->reviewer;
|
||||
sem["review"] = obj;
|
||||
}
|
||||
else if (a->conceptType == "AutomatabilityAnnotation") {
|
||||
auto* aa = static_cast<const AutomatabilityAnnotation*>(a);
|
||||
json obj;
|
||||
if (!aa->strategy.empty()) obj["strategy"] = aa->strategy;
|
||||
if (aa->confidence > 0.0) obj["confidence"] = aa->confidence;
|
||||
sem["automatability"] = obj;
|
||||
}
|
||||
else if (a->conceptType == "PriorityAnnotation") {
|
||||
auto* pa = static_cast<const PriorityAnnotation*>(a);
|
||||
if (!pa->level.empty()) sem["priority"] = pa->level;
|
||||
}
|
||||
else if (a->conceptType == "ImplementationStatusAnnotation") {
|
||||
auto* isa = static_cast<const ImplementationStatusAnnotation*>(a);
|
||||
if (!isa->status.empty()) sem["implStatus"] = isa->status;
|
||||
}
|
||||
// Environment Layer (Step 285)
|
||||
else if (a->conceptType == "CapabilityRequirement") {
|
||||
auto* cr = static_cast<const CapabilityRequirement*>(a);
|
||||
|
||||
Reference in New Issue
Block a user