botbottingbot commited on
Commit
44f9371
·
verified ·
1 Parent(s): 5781e68

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +317 -4
README.md CHANGED
@@ -1,6 +1,319 @@
1
  ---
 
2
  license: mit
3
- base_model:
4
- - openai-community/gpt2-large
5
- - openai-community/gpt2
6
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+ library_name: transformers
3
  license: mit
4
+ base_model: openai-community/gpt2
5
+ language:
6
+ - en
7
+ tags:
8
+ - modular-intelligence
9
+ - text-generation
10
+ - structured-reasoning
11
+ - experimental
12
+ ---
13
+
14
+ # Modular Intelligence (GPT-2 baseline)
15
+
16
+ This repository is an **experimental baseline** for **Modular Intelligence** built on top of `openai-community/gpt2`.
17
+
18
+ The goal is **not** to claim that GPT-2 is “intelligent”, but to show how a **small, simple model** can be wrapped inside a **modular reasoning architecture**:
19
+
20
+ - **Modules**: small, single-purpose “skills” (e.g. analysis note, strategy memo).
21
+ - **Checkers**: strict reviewers that check the output of a module.
22
+ - **Structured outputs**: fixed sections like CONTEXT / OPTIONS / RISKS / NEXT STEPS.
23
+
24
+ Later, this same architecture can be reused with much stronger models.
25
+
26
+ ---
27
+
28
+ ## What this model is
29
+
30
+ - A **GPT-2 checkpoint** configured as the engine behind a **Modular Intelligence** framework.
31
+ - It is **not** heavily fine-tuned; it is used mainly to demonstrate:
32
+ - Structured prompts
33
+ - Module definitions
34
+ - Checker patterns
35
+ - Deterministic, repeatable formats
36
+
37
+ Think of this repo as:
38
+
39
+ > “The engine inside a modular reasoning system, using GPT-2 for a minimal, low-cost demo.”
40
+
41
+ ---
42
+
43
+ ## What’s different from base GPT-2?
44
+
45
+ Base GPT-2 is a generic text generator.
46
+
47
+ Here, GPT-2 is wrapped in a **specific contract**:
48
+
49
+ 1. **Fixed module types**
50
+ For example:
51
+ - `analysis_note_v1`
52
+ - `document_explainer_v1`
53
+ - `strategy_memo_v1`
54
+ - `message_reply_v1`
55
+ - `profile_application_v1`
56
+ - `system_blueprint_v1`
57
+ - `modular_brainstorm_v1`
58
+
59
+ 2. **Fixed output sections**
60
+ Each module must respond in a strict, labelled format. Example (Strategy Memo):
61
+
62
+ - CONTEXT
63
+ - OBJECTIVE
64
+ - CONSTRAINTS
65
+ - OPTIONS
66
+ - RECOMMENDATION
67
+ - RISKS
68
+ - NEXT_ACTIONS
69
+
70
+ 3. **Paired checkers**
71
+ Certain modules have a checker module that:
72
+ - Re-reads the original task
73
+ - Reviews the draft output
74
+ - Returns a verdict + issues + suggested fixes
75
+
76
+ 4. **Use pattern**
77
+ Instead of “just generating text”, you:
78
+ - Call a **module** with structured inputs
79
+ - Get a **structured output**
80
+ - Optionally call a **checker** on that output
81
+
82
+ So the “intelligence” here is in the **architecture and prompts**, not in new weights.
83
+
84
+ ---
85
+
86
+ ## Dataset
87
+
88
+ This repository **does not introduce** a new training dataset and **does not re-train** GPT-2.
89
+
90
+ - **Base model**: `openai-community/gpt2`
91
+ - **Training objective**: next-token prediction (causal language modeling)
92
+ - **Original GPT-2 pretraining data** (by OpenAI, not included here):
93
+ - Large, general-domain English web corpus (“WebText”)
94
+ - ~40 GB of text from web pages linked from Reddit posts with score ≥ 3
95
+ - Mixed content (news, blogs, forums, technical/non-technical)
96
+
97
+ In this repository:
98
+
99
+ - GPT-2 is used **as-is** as the language engine.
100
+ - The **Modular Intelligence** behaviour comes from:
101
+ - The **module prompts** (how we talk to the model)
102
+ - The **checker prompts** (how we review its answers)
103
+ - The **fixed output formats**
104
+
105
+ No new datasets are uploaded or used for further fine-tuning inside this repo.
106
+
107
+ ---
108
+
109
+ ## Modular Intelligence: modules and checkers (simple view)
110
+
111
+ ### Generator modules
112
+
113
+ Each generator is a “skill” with a fixed format.
114
+
115
+ 1. **Analysis Note (`analysis_note_v1`)**
116
+
117
+ - **Inputs**:
118
+ - `context` – short description of the situation or text
119
+ - `questions` – what you want to understand
120
+ - `constraints` – any limits (time, style, scope)
121
+
122
+ - **Outputs (sections)**:
123
+ - CONTEXT
124
+ - QUESTIONS
125
+ - FRAMEWORK
126
+ - ANALYSIS
127
+ - CONCLUSION
128
+ - NEXT_STEPS
129
+
130
+ 2. **Document Explainer (`document_explainer_v1`)**
131
+
132
+ - **Inputs**:
133
+ - `document_text`
134
+ - `focus`
135
+ - `audience`
136
+
137
+ - **Outputs**:
138
+ - SNAPSHOT
139
+ - KEY_POINTS
140
+ - STRUCTURE
141
+ - DETAILED_EXPLANATION
142
+ - IMPLICATIONS
143
+ - ACTIONS
144
+
145
+ 3. **Strategy Memo (`strategy_memo_v1`)**
146
+
147
+ - **Inputs**:
148
+ - `context`
149
+ - `objective`
150
+ - `constraints`
151
+
152
+ - **Outputs**:
153
+ - CONTEXT
154
+ - OBJECTIVE
155
+ - CONSTRAINTS
156
+ - OPTIONS
157
+ - RECOMMENDATION
158
+ - RISKS
159
+ - NEXT_ACTIONS
160
+
161
+ 4. **Message / Post Reply (`message_reply_v1`)**
162
+
163
+ - **Inputs**:
164
+ - `source_text`
165
+ - `your_angle`
166
+ - `tone_notes`
167
+
168
+ - **Outputs**:
169
+ - DRAFT_REPLY
170
+
171
+ 5. **Profile / Application Draft (`profile_application_v1`)**
172
+
173
+ - **Inputs**:
174
+ - `target_role_or_goal`
175
+ - `your_background`
176
+ - `audience`
177
+
178
+ - **Outputs**:
179
+ - POSITIONING
180
+ - KEY_POINTS
181
+ - FULL_DRAFT
182
+
183
+ 6. **System / Architecture Blueprint (`system_blueprint_v1`)**
184
+
185
+ - **Inputs**:
186
+ - `objective`
187
+ - `current_state`
188
+ - `constraints`
189
+
190
+ - **Outputs**:
191
+ - OBJECTIVE
192
+ - CURRENT_STATE
193
+ - COMPONENTS
194
+ - FLOWS
195
+ - RISKS
196
+ - IMPROVEMENTS
197
+ - NEXT_STEPS
198
+
199
+ 7. **Modular Brainstorm (`modular_brainstorm_v1`)**
200
+
201
+ - **Inputs**:
202
+ - `problem_or_domain`
203
+ - `goal`
204
+
205
+ - **Outputs**:
206
+ - OBJECTIVE
207
+ - CURRENT
208
+ - MODULES
209
+ - CHECKERS
210
+ - DATA_NEEDS
211
+ - NEXT_STEPS
212
+
213
+ ---
214
+
215
+ ### Checker modules
216
+
217
+ Checkers are “reviewers” that inspect generated outputs.
218
+
219
+ Examples:
220
+
221
+ 1. **Analysis Note Checker (`analysis_note_checker_v1`)**
222
+
223
+ - **Inputs**:
224
+ - `original_task`
225
+ - `draft_output`
226
+
227
+ - **Outputs**:
228
+ - VERDICT
229
+ - STRUCTURE
230
+ - CLARITY
231
+ - ALIGNMENT
232
+ - GAPS
233
+ - FIXES
234
+
235
+ 2. **Document Explainer Checker (`document_explainer_checker_v1`)**
236
+
237
+ - VERDICT
238
+ - ACCURACY
239
+ - STRUCTURE
240
+ - AUDIENCE_FIT
241
+ - MISSING
242
+ - FIXES
243
+
244
+ 3. **Strategy Memo Checker (`strategy_memo_checker_v1`)**
245
+
246
+ - VERDICT
247
+ - OBJECTIVE_ALIGNMENT
248
+ - CONSTRAINT_HANDLING
249
+ - OPTION_QUALITY
250
+ - RISKS
251
+ - FIXES
252
+
253
+ 4. **Style & Voice Checker (`style_voice_checker_v1`)**
254
+
255
+ - VERDICT
256
+ - STYLE_MATCH
257
+ - TONE
258
+ - REDUNDANCY
259
+ - SUGGESTIONS
260
+
261
+ 5. **Profile Checker (`profile_checker_v1`)**
262
+
263
+ - VERDICT
264
+ - ALIGNMENT
265
+ - SIGNAL
266
+ - CLARITY
267
+ - FIXES
268
+
269
+ 6. **System Checker (`system_blueprint_checker_v1`)**
270
+
271
+ - VERDICT
272
+ - COHERENCE
273
+ - GAPS
274
+ - FLOW_ISSUES
275
+ - RISKS
276
+ - FIXES
277
+
278
+ ---
279
+
280
+ ## How to use this model (simple)
281
+
282
+ You can treat this model like any GPT-2 text generator, **but** if you want Modular Intelligence behaviour:
283
+
284
+ 1. Pick a module (e.g. `strategy_memo_v1`).
285
+ 2. Build a prompt that:
286
+ - States the module name
287
+ - Lists the inputs clearly
288
+ - Lists the required output sections
289
+
290
+ 3. Ask the model to **fill in each section in order**.
291
+ 4. Optionally call the corresponding checker with:
292
+ - Original task
293
+ - Draft output
294
+
295
+ A reference implementation and UI are provided in the accompanying Hugging Face Space (if linked), but the pattern can be re-implemented in any environment.
296
+
297
+ ---
298
+
299
+ ## Limitations
300
+
301
+ - GPT-2 is **small and outdated** by modern standards.
302
+ - It will:
303
+ - Hallucinate
304
+ - Get facts wrong
305
+ - Sometimes ignore structure
306
+ - Struggle with long contexts
307
+
308
+ The goal is to demonstrate the **architecture**, not to claim state-of-the-art performance.
309
+
310
+ Do **not** use this model for high-stakes decisions or any application where mistakes could cause real harm.
311
+
312
+ ---
313
+
314
+ ## License and IP
315
+
316
+ - Code and configuration: **MIT License**.
317
+ - The **Modular Intelligence architecture, module definitions, and checker patterns** are a conceptual layer that can be reused and extended, but the name and approach may be treated as separate intellectual property by the author.
318
+
319
+ Always review the base model’s license (`openai-community/gpt2`) for any additional constraints.