@longtable/core 0.1.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/README.md ADDED
@@ -0,0 +1,11 @@
1
+ # @longtable/core
2
+
3
+ Provider-neutral domain contracts for LongTable.
4
+
5
+ Current responsibilities:
6
+
7
+ - core research object definitions
8
+ - decision record contracts
9
+ - interaction mode contracts
10
+ - narrative trace contracts
11
+ - runtime guidance types used by adapters
@@ -0,0 +1 @@
1
+ export * from "./types.js";
package/dist/index.js ADDED
@@ -0,0 +1 @@
1
+ export * from "./types.js";
@@ -0,0 +1,110 @@
1
+ export type ExperienceLevel = "novice" | "intermediate" | "advanced";
2
+ export type CheckpointIntensity = "low" | "balanced" | "high";
3
+ export type InteractionMode = "explore" | "review" | "critique" | "draft" | "commit" | "submit";
4
+ export type ArtifactStakes = "private_note" | "internal_draft" | "study_protocol" | "external_submission";
5
+ export type ResearchStage = "problem_framing" | "theory_selection" | "method_design" | "measurement_design" | "analysis_planning" | "writing" | "submission";
6
+ export type ConfidenceLevel = "low" | "medium" | "high";
7
+ export type NarrativeTraceType = "experience" | "judgment" | "voice" | "context" | "tension";
8
+ export type NarrativeTraceVisibility = "explicit" | "inferred";
9
+ export type HypothesisStatus = "unconfirmed" | "confirmed" | "rejected";
10
+ export type ProviderKind = "claude" | "codex";
11
+ export type CheckpointLevel = "universal_required" | "adaptive_required" | "recommended" | "log_only" | "none";
12
+ export type PromptStyle = "structured_choice" | "confirm_or_revise" | "advisory_summary" | "passive_log";
13
+ export type GuidanceQuestionType = "clarifying" | "boundary" | "tension" | "narrative";
14
+ export type ClosureDisposition = "delay" | "tentative" | "strong" | "strongest";
15
+ export interface ResearcherConfidenceByDomain {
16
+ theory: ConfidenceLevel;
17
+ methodology: ConfidenceLevel;
18
+ measurement: ConfidenceLevel;
19
+ analysis: ConfidenceLevel;
20
+ writing: ConfidenceLevel;
21
+ }
22
+ export interface ResearcherProfile {
23
+ field: string;
24
+ careerStage: string;
25
+ experienceLevel: ExperienceLevel;
26
+ preferredCheckpointIntensity: CheckpointIntensity;
27
+ currentProjectType: string;
28
+ humanAuthorshipSignal?: string;
29
+ aiAutonomyPreference?: "low" | "balanced" | "high";
30
+ forceCheckpointsOn?: string[];
31
+ relaxCheckpointsOn?: string[];
32
+ confidenceByDomain?: Partial<ResearcherConfidenceByDomain>;
33
+ }
34
+ export interface InferredHypothesis {
35
+ hypothesis: string;
36
+ confidence: number;
37
+ evidence: string[];
38
+ status: HypothesisStatus;
39
+ }
40
+ export interface DecisionRecord {
41
+ id: string;
42
+ timestamp: string;
43
+ checkpointKey: string;
44
+ level: CheckpointLevel;
45
+ mode: InteractionMode;
46
+ summary: string;
47
+ selectedOption?: string;
48
+ rationale?: string;
49
+ explicitStateUpdates?: Record<string, unknown>;
50
+ studyContractId?: string;
51
+ }
52
+ export interface ArtifactRecord {
53
+ id: string;
54
+ timestamp: string;
55
+ artifactType: string;
56
+ stakes: ArtifactStakes;
57
+ source: string;
58
+ provider?: ProviderKind;
59
+ location?: string;
60
+ decisionRecordId?: string;
61
+ provenanceSummary: string;
62
+ }
63
+ export interface NarrativeTrace {
64
+ id: string;
65
+ timestamp: string;
66
+ source: string;
67
+ traceType: NarrativeTraceType;
68
+ summary: string;
69
+ visibility: NarrativeTraceVisibility;
70
+ importance: ConfidenceLevel;
71
+ linkedDecisionRecordId?: string;
72
+ }
73
+ export interface RuntimeGuidance {
74
+ mode: InteractionMode;
75
+ minimumQuestions: number;
76
+ questionTypes: GuidanceQuestionType[];
77
+ mustAskBeforeClosure: boolean;
78
+ preferQuestionsFirst: boolean;
79
+ includeUnaskedQuestions: boolean;
80
+ includeOpenTensions: boolean;
81
+ includeWhyMayBeWrong: boolean;
82
+ preserveNarrativeTrace: boolean;
83
+ surfaceHumanCommitment: boolean;
84
+ closureDisposition: ClosureDisposition;
85
+ mandatoryQuestions: string[];
86
+ rationale: string[];
87
+ }
88
+ export interface StudyContract {
89
+ id: string;
90
+ title: string;
91
+ problemFraming: string;
92
+ targetVenue?: string;
93
+ theoryAnchor: string;
94
+ methodology: string;
95
+ measurementPlan: string;
96
+ analysisPlan?: string;
97
+ currentStage: ResearchStage;
98
+ openTensions: string[];
99
+ decisionRecordIds: string[];
100
+ }
101
+ export interface ResearchState {
102
+ explicitState: Record<string, unknown>;
103
+ workingState: Record<string, unknown>;
104
+ inferredHypotheses: InferredHypothesis[];
105
+ openTensions: string[];
106
+ decisionLog: DecisionRecord[];
107
+ artifactRecords: ArtifactRecord[];
108
+ narrativeTraces: NarrativeTrace[];
109
+ studyContract?: StudyContract;
110
+ }
package/dist/types.js ADDED
@@ -0,0 +1 @@
1
+ export {};
package/package.json ADDED
@@ -0,0 +1,45 @@
1
+ {
2
+ "name": "@longtable/core",
3
+ "version": "0.1.9",
4
+ "private": false,
5
+ "description": "Provider-neutral domain models and contracts for LongTable",
6
+ "type": "module",
7
+ "main": "./dist/index.js",
8
+ "types": "./dist/index.d.ts",
9
+ "files": [
10
+ "dist",
11
+ "README.md"
12
+ ],
13
+ "exports": {
14
+ ".": {
15
+ "types": "./dist/index.d.ts",
16
+ "import": "./dist/index.js"
17
+ }
18
+ },
19
+ "scripts": {
20
+ "build": "tsc -p tsconfig.json",
21
+ "typecheck": "tsc -p tsconfig.json --noEmit"
22
+ },
23
+ "keywords": [
24
+ "longtable",
25
+ "research",
26
+ "contracts",
27
+ "types"
28
+ ],
29
+ "author": "Hosung You",
30
+ "license": "MIT",
31
+ "repository": {
32
+ "type": "git",
33
+ "url": "git+https://github.com/HosungYou/LongTable.git"
34
+ },
35
+ "homepage": "https://github.com/HosungYou/LongTable#readme",
36
+ "publishConfig": {
37
+ "access": "public"
38
+ },
39
+ "engines": {
40
+ "node": ">=18.0.0"
41
+ },
42
+ "devDependencies": {
43
+ "typescript": "^5.6.0"
44
+ }
45
+ }