Spaces:
Running
Running
Update README.md
Browse files
README.md
CHANGED
|
@@ -1,13 +1,38 @@
|
|
| 1 |
---
|
| 2 |
title: CodeBook
|
| 3 |
-
emoji:
|
| 4 |
-
colorFrom:
|
| 5 |
-
colorTo:
|
| 6 |
sdk: gradio
|
| 7 |
sdk_version: 5.49.1
|
| 8 |
app_file: app.py
|
| 9 |
-
pinned:
|
| 10 |
short_description: Advanced AI workflowing system.
|
| 11 |
---
|
| 12 |
|
| 13 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
---
|
| 2 |
title: CodeBook
|
| 3 |
+
emoji: π
|
| 4 |
+
colorFrom: purple
|
| 5 |
+
colorTo: red
|
| 6 |
sdk: gradio
|
| 7 |
sdk_version: 5.49.1
|
| 8 |
app_file: app.py
|
| 9 |
+
pinned: true
|
| 10 |
short_description: Advanced AI workflowing system.
|
| 11 |
---
|
| 12 |
|
| 13 |
+
# π€ CodeBook AI Workflow Space: Code or Book Generator with Self-Critique
|
| 14 |
+
|
| 15 |
+
This Hugging Face Space refines an **idea** into either:
|
| 16 |
+
- A *complete code project* (pseudocode β snippet β full code), or
|
| 17 |
+
- A *structured story* (Start β Development β Climax β Conclusion β End).
|
| 18 |
+
|
| 19 |
+
After creation, **two AI critics** rate and explain the output, and the system automatically refines it based on their feedback β a full *AI self-improvement loop*.
|
| 20 |
+
|
| 21 |
+
## π§© Workflow
|
| 22 |
+
|
| 23 |
+
1. Input your **idea** and choose **Code mode** or **Book mode**.
|
| 24 |
+
2. The AI refines your prompt.
|
| 25 |
+
3. It builds content step-by-step.
|
| 26 |
+
4. Two critics analyze and rate it.
|
| 27 |
+
5. The main model refines the output using that feedback.
|
| 28 |
+
|
| 29 |
+
## π οΈ Models Used
|
| 30 |
+
- Prompt refiner: `mistralai/Mixtral-8x7B-Instruct-v0.1`
|
| 31 |
+
- Code generator: `codellama/CodeLlama-7b-Instruct-hf`
|
| 32 |
+
- Book generator: `mistralai/Mixtral-8x7B-Instruct-v0.1`
|
| 33 |
+
- Critics: `google/gemma-2-9b-it`, `meta-llama/Meta-Llama-3-8B-Instruct`
|
| 34 |
+
|
| 35 |
+
You can modify these to lighter or open-source models depending on performance limits.
|
| 36 |
+
|
| 37 |
+
## π Deployment
|
| 38 |
+
Push this repo to Hugging Face as a Space and select βGradioβ as the SDK.
|