deckbuilder 1.0.0b1__tar.gz
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.
- deckbuilder-1.0.0b1/CLAUDE.md +317 -0
- deckbuilder-1.0.0b1/LICENSE +201 -0
- deckbuilder-1.0.0b1/MANIFEST.in +63 -0
- deckbuilder-1.0.0b1/PKG-INFO +378 -0
- deckbuilder-1.0.0b1/PLANNING.md +383 -0
- deckbuilder-1.0.0b1/README.md +323 -0
- deckbuilder-1.0.0b1/TASK.md +310 -0
- deckbuilder-1.0.0b1/assets/templates/default.json +270 -0
- deckbuilder-1.0.0b1/assets/templates/default.pptx +0 -0
- deckbuilder-1.0.0b1/bandit.yaml +4 -0
- deckbuilder-1.0.0b1/docs/API.md +192 -0
- deckbuilder-1.0.0b1/docs/BACKEND.md +123 -0
- deckbuilder-1.0.0b1/docs/Features/Convention_Based_Naming.md +184 -0
- deckbuilder-1.0.0b1/docs/Features/Deckbuilder_CLI.md +344 -0
- deckbuilder-1.0.0b1/docs/Features/Deckbuilder_Content_Intelligence.md +381 -0
- deckbuilder-1.0.0b1/docs/Features/Deckbuilder_Core_API.md +449 -0
- deckbuilder-1.0.0b1/docs/Features/Deckbuilder_Python_Library.md +185 -0
- deckbuilder-1.0.0b1/docs/Features/Deckbuilder_Quick_Start.md +300 -0
- deckbuilder-1.0.0b1/docs/Features/Deckbuilder_Template_Management.md +390 -0
- deckbuilder-1.0.0b1/docs/Features/Default_Template.md +113 -0
- deckbuilder-1.0.0b1/docs/Features/Image_Support.md +411 -0
- deckbuilder-1.0.0b1/docs/Features/Place_Kitten.md +310 -0
- deckbuilder-1.0.0b1/docs/Features/Placeholder_Matching.md +495 -0
- deckbuilder-1.0.0b1/docs/Features/Supported_Templates.md +129 -0
- deckbuilder-1.0.0b1/docs/Features/Template_Discovery.md +599 -0
- deckbuilder-1.0.0b1/docs/Features/Template_Management.md +272 -0
- deckbuilder-1.0.0b1/docs/Features/Testing_Framework.md +473 -0
- deckbuilder-1.0.0b1/docs/list-content-spec.md +100 -0
- deckbuilder-1.0.0b1/docs/table-styles.css +253 -0
- deckbuilder-1.0.0b1/docs/table-styles.html +342 -0
- deckbuilder-1.0.0b1/examples/advanced_features.md +120 -0
- deckbuilder-1.0.0b1/examples/basic_presentation.md +86 -0
- deckbuilder-1.0.0b1/examples/json_example.json +81 -0
- deckbuilder-1.0.0b1/pyproject.toml +130 -0
- deckbuilder-1.0.0b1/pytest.ini +21 -0
- deckbuilder-1.0.0b1/requirements.txt +32 -0
- deckbuilder-1.0.0b1/setup.cfg +4 -0
- deckbuilder-1.0.0b1/src/deckbuilder/__init__.py +22 -0
- deckbuilder-1.0.0b1/src/deckbuilder/cli.py +544 -0
- deckbuilder-1.0.0b1/src/deckbuilder/cli_tools.py +739 -0
- deckbuilder-1.0.0b1/src/deckbuilder/engine.py +1546 -0
- deckbuilder-1.0.0b1/src/deckbuilder/image_handler.py +291 -0
- deckbuilder-1.0.0b1/src/deckbuilder/layout_intelligence.json +288 -0
- deckbuilder-1.0.0b1/src/deckbuilder/layout_intelligence.py +398 -0
- deckbuilder-1.0.0b1/src/deckbuilder/naming_conventions.py +541 -0
- deckbuilder-1.0.0b1/src/deckbuilder/placeholder_types.py +101 -0
- deckbuilder-1.0.0b1/src/deckbuilder/placekitten_integration.py +280 -0
- deckbuilder-1.0.0b1/src/deckbuilder/structured_frontmatter.py +862 -0
- deckbuilder-1.0.0b1/src/deckbuilder/table_styles.py +37 -0
- deckbuilder-1.0.0b1/src/deckbuilder.egg-info/PKG-INFO +378 -0
- deckbuilder-1.0.0b1/src/deckbuilder.egg-info/SOURCES.txt +75 -0
- deckbuilder-1.0.0b1/src/deckbuilder.egg-info/dependency_links.txt +1 -0
- deckbuilder-1.0.0b1/src/deckbuilder.egg-info/entry_points.txt +3 -0
- deckbuilder-1.0.0b1/src/deckbuilder.egg-info/requires.txt +26 -0
- deckbuilder-1.0.0b1/src/deckbuilder.egg-info/top_level.txt +4 -0
- deckbuilder-1.0.0b1/src/mcp_server/__init__.py +9 -0
- deckbuilder-1.0.0b1/src/mcp_server/content_analysis.py +436 -0
- deckbuilder-1.0.0b1/src/mcp_server/content_optimization.py +822 -0
- deckbuilder-1.0.0b1/src/mcp_server/layout_recommendations.py +595 -0
- deckbuilder-1.0.0b1/src/mcp_server/main.py +550 -0
- deckbuilder-1.0.0b1/src/mcp_server/tools.py +492 -0
- deckbuilder-1.0.0b1/src/placekitten/README.md +561 -0
- deckbuilder-1.0.0b1/src/placekitten/__init__.py +44 -0
- deckbuilder-1.0.0b1/src/placekitten/core.py +184 -0
- deckbuilder-1.0.0b1/src/placekitten/filters.py +183 -0
- deckbuilder-1.0.0b1/src/placekitten/images/ACuteKitten-1.png +0 -0
- deckbuilder-1.0.0b1/src/placekitten/images/ACuteKitten-2.png +0 -0
- deckbuilder-1.0.0b1/src/placekitten/images/ACuteKitten-3.png +0 -0
- deckbuilder-1.0.0b1/src/placekitten/images/TwoKitttens Playing-1.png +0 -0
- deckbuilder-1.0.0b1/src/placekitten/images/TwoKitttens Playing-2.png +0 -0
- deckbuilder-1.0.0b1/src/placekitten/images/TwoKitttensSleeping-1.png +0 -0
- deckbuilder-1.0.0b1/src/placekitten/processor.py +262 -0
- deckbuilder-1.0.0b1/src/placekitten/smart_crop.py +314 -0
- deckbuilder-1.0.0b1/src/shared/__init__.py +9 -0
- deckbuilder-1.0.0b1/tests/deckbuilder/fixtures/sample_templates/default_template.json +69 -0
- deckbuilder-1.0.0b1/tests/deckbuilder/test_presentation.json +194 -0
- deckbuilder-1.0.0b1/tests/deckbuilder/test_presentation.md +145 -0
@@ -0,0 +1,317 @@
|
|
1
|
+
# CLAUDE.md
|
2
|
+
|
3
|
+
## Project Overview
|
4
|
+
|
5
|
+
Deckbuilder is a Python library and accompanying MCP (Model Context Protocol) Server for intelligent PowerPoint presentation generation.
|
6
|
+
The project has evolved beyond initial setup into a comprehensive content-first presentation intelligence system.
|
7
|
+
|
8
|
+
### 🔄 Project Awareness & Context
|
9
|
+
- **Always read `PLANNING.md`** at the start of a new conversation to understand the project's architecture, goals, style, and constraints.
|
10
|
+
- **Check `TASK.md`** before starting a new task. If the task isn’t listed, add it with a brief description and today's date.
|
11
|
+
- **Use consistent naming conventions, file structure, and architecture patterns** as described in `PLANNING.md`.
|
12
|
+
|
13
|
+
### 🧱 Code Structure & Modularity
|
14
|
+
- **Never create a file longer than 500 lines of code.** If a file approaches this limit, refactor by splitting it into modules or helper files.
|
15
|
+
- **Organize code into clearly separated modules**, grouped by feature or responsibility.
|
16
|
+
- **Use clear, consistent imports** (prefer relative imports within packages).
|
17
|
+
|
18
|
+
### 🧪 Testing & Reliability
|
19
|
+
- **Always create Pytest unit tests for new features** (functions, classes, routes, etc).
|
20
|
+
- **After updating any logic**, check whether existing unit tests need to be updated. If so, do it.
|
21
|
+
- **Tests should live in a `/tests` folder** mirroring the main app structure.
|
22
|
+
- Include at least:
|
23
|
+
- 1 test for expected use
|
24
|
+
- 1 edge case
|
25
|
+
- 1 failure case
|
26
|
+
|
27
|
+
### ✅ Task Completion
|
28
|
+
- **Mark completed tasks in `TASK.md`** immediately after finishing them.
|
29
|
+
- Add new sub-tasks or TODOs discovered during development to `TASK.md` under a “Discovered During Work” section.
|
30
|
+
|
31
|
+
### 📎 Style & Conventions
|
32
|
+
- **Use Python** as the primary language.
|
33
|
+
- **Follow PEP8**, use type hints, and format with `black`.
|
34
|
+
- **Run flake8**, and fix any errors before check-in.
|
35
|
+
- **Use `pydantic` for data validation**.
|
36
|
+
|
37
|
+
|
38
|
+
## 🔧 Code Quality Standards
|
39
|
+
|
40
|
+
**CRITICAL: Always run these commands and fix ALL errors before committing:**
|
41
|
+
|
42
|
+
```bash
|
43
|
+
# Format code with black (REQUIRED)
|
44
|
+
black --line-length 100 src/
|
45
|
+
|
46
|
+
# Check all flake8 violations (REQUIRED)
|
47
|
+
flake8 src/ tests/ --max-line-length=100 --ignore=E203,W503,E501
|
48
|
+
|
49
|
+
# Run tests to ensure no regressions (REQUIRED)
|
50
|
+
pytest tests/
|
51
|
+
```
|
52
|
+
|
53
|
+
**⚠️ ZERO TOLERANCE POLICY: No commits allowed with flake8 F-level errors (F401, F841, F811, F541, etc.)**
|
54
|
+
|
55
|
+
|
56
|
+
|
57
|
+
|
58
|
+
### Code Quality Rules
|
59
|
+
|
60
|
+
**Imports (Critical F-level violations):**
|
61
|
+
- Remove ALL unused imports (F401) - check each import statement
|
62
|
+
- Import order: stdlib → third-party → local, alphabetical within groups
|
63
|
+
- Use `# noqa: E402` only when imports must follow `sys.path.insert()`
|
64
|
+
- Never duplicate imports (F811)
|
65
|
+
|
66
|
+
**Variables (Critical F-level violations):**
|
67
|
+
- Remove ALL unused variables (F841) - either use them or delete them
|
68
|
+
- Use `_` for intentionally unused variables: `for _, item in enumerate(items)`
|
69
|
+
- Comment out variables for future use: `# content_length = len(content) # Future: use for analysis`
|
70
|
+
|
71
|
+
**F-strings (Critical F-level violations):**
|
72
|
+
- Fix ALL f-strings without placeholders (F541): `f"Hello"` → `"Hello"`
|
73
|
+
- Only use f-strings when you have variables: `f"Hello {name}"`
|
74
|
+
|
75
|
+
**Line Length (E501 - Style violations):**
|
76
|
+
- Maximum 100 characters per line (ignored in CI for now)
|
77
|
+
- Break long function calls, docstrings, and string literals when practical
|
78
|
+
- Use parentheses for continuation: `("long string part 1 "\n"part 2")`
|
79
|
+
- **Note**: E501 ignored in CI to focus on critical F-level errors first
|
80
|
+
|
81
|
+
### Enforcement Strategy
|
82
|
+
1. **Pre-commit**: Always run `flake8` before any commit
|
83
|
+
2. **Zero F-errors**: F-level errors MUST be fixed immediately
|
84
|
+
3. **Style consistency**: Use `black` for automatic formatting
|
85
|
+
4. **Test coverage**: Ensure all code changes include relevant tests
|
86
|
+
|
87
|
+
### CI Integration
|
88
|
+
The project includes GitHub Actions workflows that enforce code quality:
|
89
|
+
|
90
|
+
- **`.github/workflows/test.yml`**: Runs pytest and flake8 on every push/PR
|
91
|
+
- **`.github/workflows/claude-code-review.yml`**: Claude-powered code review for PRs
|
92
|
+
|
93
|
+
**CI Requirements:**
|
94
|
+
- All tests must pass (50+ tests including engine, template processing, etc.)
|
95
|
+
- Zero flake8 F-level errors (F401, F841, F811, F541)
|
96
|
+
- Python 3.11+ compatibility required
|
97
|
+
|
98
|
+
|
99
|
+
|
100
|
+
**Current Status**:
|
101
|
+
- ✅ Core presentation engine implemented with structured frontmatter support
|
102
|
+
- ✅ Template system with semantic detection and JSON mapping
|
103
|
+
- 🚧 Content-first MCP tools in design phase
|
104
|
+
- 📋 50+ layout templates planned for progressive implementation
|
105
|
+
|
106
|
+
## Architecture
|
107
|
+
|
108
|
+
Deckbuilder implements a **content-first design philosophy** with three key components:
|
109
|
+
1. **Presentation Engine**: PowerPoint generation with template support
|
110
|
+
2. **Content Intelligence**: Semantic analysis for layout recommendations
|
111
|
+
3. **Progressive Templates**: Expanding library of business presentation layouts
|
112
|
+
|
113
|
+
The system transforms LLMs from layout pickers into intelligent presentation consultants.
|
114
|
+
|
115
|
+
## Development Environment
|
116
|
+
|
117
|
+
Always use Python 3.11+ and activate the virtual environment:
|
118
|
+
```bash
|
119
|
+
source .venv/bin/activate
|
120
|
+
```
|
121
|
+
|
122
|
+
## ⚠️ IMPORTANT: MCP Server Environment Configuration
|
123
|
+
|
124
|
+
**When testing the engine directly (not through MCP)**, the presentation engine will fail to load template mappings because environment variables are not set. Environment variables are configured in the MCP server parameters, not in local `.env` files.
|
125
|
+
|
126
|
+
**MCP Server Configuration** (Claude Desktop config):
|
127
|
+
```json
|
128
|
+
{
|
129
|
+
"env": {
|
130
|
+
"DECK_TEMPLATE_FOLDER": "/path/to/deckbuilder/assets/templates",
|
131
|
+
"DECK_OUTPUT_FOLDER": "/path/to/deckbuilder/output",
|
132
|
+
"DECK_TEMPLATE_NAME": "default"
|
133
|
+
}
|
134
|
+
}
|
135
|
+
```
|
136
|
+
|
137
|
+
**Impact on Development**:
|
138
|
+
- ✅ **MCP tools work correctly** - environment variables are available
|
139
|
+
- ❌ **Direct engine testing may fail** - missing template paths cause fallback to minimal layout mapping
|
140
|
+
- ❌ **Layout selection issues** - incorrect layouts selected when template mapping not loaded
|
141
|
+
|
142
|
+
**Testing Workaround**: When testing engine directly, manually set environment variables or expect fallback behavior with limited layouts.
|
143
|
+
|
144
|
+
## Design Approach
|
145
|
+
|
146
|
+
# How you work
|
147
|
+
1. Design a feature first, remind me to put you into plan-only mode
|
148
|
+
2. Save that design into ./docs/Features/feature_name.md
|
149
|
+
3. At the bottom of the design put a TODO which you implement as we go.
|
150
|
+
|
151
|
+
This project follows a **content-first methodology**:
|
152
|
+
1. **Understand user content and communication goals first**
|
153
|
+
2. **Recommend presentation structure based on message intent**
|
154
|
+
3. **Suggest optimal layouts with audience consideration**
|
155
|
+
4. **Optimize content for chosen layouts**
|
156
|
+
|
157
|
+
Never start with "what layouts exist?" - always start with "what does the user want to communicate?"
|
158
|
+
|
159
|
+
## Key Design Decisions
|
160
|
+
|
161
|
+
### Content Intelligence Storage
|
162
|
+
- **Decision**: Separate `layout_intelligence.json` file (Option 2)
|
163
|
+
- **Rationale**: Clean separation of technical template structure from semantic content intelligence
|
164
|
+
- **Location**: `src/layout_intelligence.json`
|
165
|
+
- **Integration**: Used by content-first MCP tools for layout recommendations
|
166
|
+
|
167
|
+
### Template Architecture
|
168
|
+
- **Technical Structure**: `default.json` (placeholder mappings)
|
169
|
+
- **Semantic Intelligence**: `layout_intelligence.json` (content matching)
|
170
|
+
- **Documentation**: `SupportedTemplates.md` (implementation roadmap)
|
171
|
+
- **Hybrid Approach**: Semantic detection + JSON mapping for reliable content placement
|
172
|
+
|
173
|
+
## Feature Documentation
|
174
|
+
|
175
|
+
Refer to these comprehensive specifications before implementing:
|
176
|
+
|
177
|
+
### Core Feature Specifications
|
178
|
+
- **[Placeholder_Matching.md](docs/Features/Placeholder_Matching.md)**:
|
179
|
+
- Hybrid semantic detection and JSON mapping system
|
180
|
+
- Template analyzer workflow and JSON schema
|
181
|
+
- Content placement strategies and troubleshooting
|
182
|
+
- **Content Intelligence Storage Design** with Option 2 decision rationale
|
183
|
+
|
184
|
+
- **[Template_Discovery.md](docs/Features/Template_Discovery.md)**:
|
185
|
+
- Content-first MCP tools design (analyze_presentation_needs, recommend_slide_approach, optimize_content_for_layout)
|
186
|
+
- Complete end-to-end user workflow scenarios
|
187
|
+
- Design evolution from layout-centric to content-first approach
|
188
|
+
- Implementation roadmap and success criteria
|
189
|
+
|
190
|
+
- **[Supported_Templates.md](docs/Features/Supported_Templates.md)**:
|
191
|
+
- Progressive implementation roadmap for 50+ business presentation layouts
|
192
|
+
- Status tracking with ✅/❌ indicators across 7 layout categories
|
193
|
+
- Required placeholders and descriptions for each layout
|
194
|
+
- Current: 12 implemented, 50+ planned
|
195
|
+
|
196
|
+
## Implementation Priorities
|
197
|
+
|
198
|
+
### Phase 1: Content-First MCP Tools ✅ COMPLETED
|
199
|
+
1. ✅ `analyze_presentation_needs()` - Content and goal analysis (placeholder implemented)
|
200
|
+
2. ✅ `recommend_slide_approach()` - Layout recommendations (placeholder implemented)
|
201
|
+
3. ✅ `optimize_content_for_layout()` - Content optimization and YAML generation (placeholder implemented)
|
202
|
+
|
203
|
+
### Phase 2: Template Management System ✅ COMPLETED
|
204
|
+
1. ✅ **CLI Template Management Tools** - Comprehensive command-line utilities
|
205
|
+
- `analyze` - Template structure analysis with detailed validation
|
206
|
+
- `document` - Auto-generated comprehensive template documentation
|
207
|
+
- `validate` - Template and mapping validation with specific fix suggestions
|
208
|
+
- `enhance` - Master slide placeholder modification with organized backup system
|
209
|
+
2. ✅ **Master Slide Enhancement** - Direct PowerPoint template modification using python-pptx
|
210
|
+
3. ✅ **Organized File Management** - `.g.pptx` convention and dedicated backup folders
|
211
|
+
4. ✅ **Comprehensive Documentation** - Updated user guides and technical specifications
|
212
|
+
|
213
|
+
### Phase 3: Content Intelligence & Layout Expansion (Current Focus)
|
214
|
+
1. **Convention-Based Naming System** - Standardized placeholder naming patterns
|
215
|
+
2. **Layout Intelligence Implementation** - `src/layout_intelligence.json` with semantic metadata
|
216
|
+
3. **Content Matching Algorithms** - Smart layout recommendations based on content analysis
|
217
|
+
4. **Template Library Expansion** - Progressive implementation of 50+ layouts from `SupportedTemplates.md`
|
218
|
+
5. **Performance Optimization** - Enhanced content intelligence and comprehensive testing
|
219
|
+
|
220
|
+
## Important Instructions
|
221
|
+
|
222
|
+
1. **🔧 CODE QUALITY FIRST**: Always run `flake8` and fix ALL F-level errors before any commit
|
223
|
+
2. **Always design a feature first, and ask me to review the design before implementing it**
|
224
|
+
3. **Follow content-first principles**: Start with user needs, not system capabilities
|
225
|
+
4. **Maintain separation of concerns**: Technical structure vs semantic intelligence
|
226
|
+
5. **Document decisions**: Update feature docs when making design choices
|
227
|
+
6. **Test with real scenarios**: Use actual user presentation needs for validation
|
228
|
+
7. **Clean imports**: Remove unused imports (F401) and variables (F841) immediately
|
229
|
+
8. **Format consistently**: Use `black --line-length 100 src/` before committing
|
230
|
+
9. **🚫 NO ROOT DIRECTORY POLLUTION**: Never create test files, output files, or temporary files in the root directory. Use appropriate subdirectories:
|
231
|
+
- Test files: `/tests/` directory with proper structure
|
232
|
+
- Output files: `/tests/output/` directory ONLY
|
233
|
+
- Temporary files: Use Python's `tempfile` module or existing `/temp/` subdirectories
|
234
|
+
- Integration tests: `/tests/integration/` directory
|
235
|
+
- Debug scripts: `/tests/debug/` directory (temporary, must be cleaned up)
|
236
|
+
- **NEVER create new directories in root** - use existing structure only
|
237
|
+
|
238
|
+
## Testing & Validation
|
239
|
+
|
240
|
+
When tests fail, ask the user how to fix them before actually fixing them.
|
241
|
+
|
242
|
+
### Test Files and Usage
|
243
|
+
|
244
|
+
The project includes comprehensive test files for validation:
|
245
|
+
|
246
|
+
#### Core Test Files
|
247
|
+
- **`tests/test_presentation.md`**: Primary markdown test with structured frontmatter examples
|
248
|
+
- Tests Four Columns, Two Content, Comparison, and Picture with Caption layouts
|
249
|
+
- Demonstrates clean YAML syntax and content optimization
|
250
|
+
- Used for end-to-end presentation generation testing
|
251
|
+
|
252
|
+
- **`tests/test_structured_frontmatter.md`**: Extended structured frontmatter examples
|
253
|
+
- Additional layout variations and edge cases
|
254
|
+
- Content formatting and validation scenarios
|
255
|
+
|
256
|
+
- **`tests/FormattingTest.md`**: Inline formatting validation
|
257
|
+
- Bold, italic, underline combinations
|
258
|
+
- Complex formatting patterns and edge cases
|
259
|
+
|
260
|
+
- **`tests/TestPrompt.md`**: User scenario testing
|
261
|
+
- Real-world presentation requests
|
262
|
+
- Content-first workflow validation
|
263
|
+
|
264
|
+
#### Template Management CLI Tools
|
265
|
+
- **`src/deckbuilder/cli_tools.py`**: Comprehensive template management utilities
|
266
|
+
- Extracts PowerPoint template structure with detailed validation
|
267
|
+
- Generates JSON mappings and comprehensive documentation
|
268
|
+
- Enhances templates with master slide placeholder modification
|
269
|
+
- Provides organized backup system and error reporting
|
270
|
+
|
271
|
+
### Running Tests
|
272
|
+
|
273
|
+
#### Template Analysis and Enhancement
|
274
|
+
Generate JSON mappings and enhance PowerPoint templates:
|
275
|
+
```bash
|
276
|
+
# Analyze template structure with validation
|
277
|
+
python src/deckbuilder/cli_tools.py analyze default --verbose
|
278
|
+
|
279
|
+
# Generate comprehensive documentation
|
280
|
+
python src/deckbuilder/cli_tools.py document default
|
281
|
+
|
282
|
+
# Validate template and mappings
|
283
|
+
python src/deckbuilder/cli_tools.py validate default
|
284
|
+
|
285
|
+
# Enhance template with corrected placeholder names
|
286
|
+
python src/deckbuilder/cli_tools.py enhance default
|
287
|
+
```
|
288
|
+
|
289
|
+
#### Presentation Generation Testing
|
290
|
+
Test structured frontmatter system:
|
291
|
+
```bash
|
292
|
+
# Through MCP client (Claude Desktop)
|
293
|
+
# Use create_presentation_from_markdown tool with test_presentation.md content
|
294
|
+
```
|
295
|
+
|
296
|
+
#### Manual Validation
|
297
|
+
1. **Content Placement**: Verify titles, content, and placeholders appear correctly
|
298
|
+
2. **Formatting**: Check bold, italic, underline rendering
|
299
|
+
3. **Layout Accuracy**: Ensure structured frontmatter maps to correct layouts
|
300
|
+
4. **Template Loading**: Verify JSON mappings work with PowerPoint templates
|
301
|
+
|
302
|
+
### Test Data Validation
|
303
|
+
|
304
|
+
The test files validate:
|
305
|
+
- **Structured frontmatter conversion**: YAML → JSON → PowerPoint
|
306
|
+
- **Content optimization**: 64% complexity reduction achieved
|
307
|
+
- **Layout intelligence**: Semantic content matching
|
308
|
+
- **Formatting preservation**: All inline formatting maintained
|
309
|
+
- **Template compatibility**: Works across different PowerPoint templates
|
310
|
+
|
311
|
+
### Output Validation
|
312
|
+
|
313
|
+
Generated presentations should demonstrate:
|
314
|
+
- Clean content placement without formatting explosion
|
315
|
+
- Proper layout selection based on content structure
|
316
|
+
- Accurate placeholder mapping using semantic detection + JSON fallback
|
317
|
+
- Professional appearance matching structured frontmatter specifications
|
@@ -0,0 +1,201 @@
|
|
1
|
+
Apache License
|
2
|
+
Version 2.0, January 2004
|
3
|
+
http://www.apache.org/licenses/
|
4
|
+
|
5
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
6
|
+
|
7
|
+
1. Definitions.
|
8
|
+
|
9
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
10
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
11
|
+
|
12
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
13
|
+
the copyright owner that is granting the License.
|
14
|
+
|
15
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
16
|
+
other entities that control, are controlled by, or are under common
|
17
|
+
control with that entity. For the purposes of this definition,
|
18
|
+
"control" means (i) the power, direct or indirect, to cause the
|
19
|
+
direction or management of such entity, whether by contract or
|
20
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
21
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
22
|
+
|
23
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
24
|
+
exercising permissions granted by this License.
|
25
|
+
|
26
|
+
"Source" form shall mean the preferred form for making modifications,
|
27
|
+
including but not limited to software source code, documentation
|
28
|
+
source, and configuration files.
|
29
|
+
|
30
|
+
"Object" form shall mean any form resulting from mechanical
|
31
|
+
transformation or translation of a Source form, including but
|
32
|
+
not limited to compiled object code, generated documentation,
|
33
|
+
and conversions to other media types.
|
34
|
+
|
35
|
+
"Work" shall mean the work of authorship, whether in Source or
|
36
|
+
Object form, made available under the License, as indicated by a
|
37
|
+
copyright notice that is included in or attached to the work
|
38
|
+
(an example is provided in the Appendix below).
|
39
|
+
|
40
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
41
|
+
form, that is based on (or derived from) the Work and for which the
|
42
|
+
editorial revisions, annotations, elaborations, or other modifications
|
43
|
+
represent, as a whole, an original work of authorship. For the purposes
|
44
|
+
of this License, Derivative Works shall not include works that remain
|
45
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
46
|
+
the Work and Derivative Works thereof.
|
47
|
+
|
48
|
+
"Contribution" shall mean any work of authorship, including
|
49
|
+
the original version of the Work and any modifications or additions
|
50
|
+
to that Work or Derivative Works thereof, that is intentionally
|
51
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
52
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
53
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
54
|
+
means any form of electronic, verbal, or written communication sent
|
55
|
+
to the Licensor or its representatives, including but not limited to
|
56
|
+
communication on electronic mailing lists, source code control systems,
|
57
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
58
|
+
Licensor for the purpose of discussing and improving the Work, but
|
59
|
+
excluding communication that is conspicuously marked or otherwise
|
60
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
61
|
+
|
62
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
63
|
+
on behalf of whom a Contribution has been received by Licensor and
|
64
|
+
subsequently incorporated within the Work.
|
65
|
+
|
66
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
67
|
+
this License, each Contributor hereby grants to You a perpetual,
|
68
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
69
|
+
copyright license to reproduce, prepare Derivative Works of,
|
70
|
+
publicly display, publicly perform, sublicense, and distribute the
|
71
|
+
Work and such Derivative Works in Source or Object form.
|
72
|
+
|
73
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
74
|
+
this License, each Contributor hereby grants to You a perpetual,
|
75
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
76
|
+
(except as stated in this section) patent license to make, have made,
|
77
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
78
|
+
where such license applies only to those patent claims licensable
|
79
|
+
by such Contributor that are necessarily infringed by their
|
80
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
81
|
+
with the Work to which such Contribution(s) was submitted. If You
|
82
|
+
institute patent litigation against any entity (including a
|
83
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
84
|
+
or a Contribution incorporated within the Work constitutes direct
|
85
|
+
or contributory patent infringement, then any patent licenses
|
86
|
+
granted to You under this License for that Work shall terminate
|
87
|
+
as of the date such litigation is filed.
|
88
|
+
|
89
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
90
|
+
Work or Derivative Works thereof in any medium, with or without
|
91
|
+
modifications, and in Source or Object form, provided that You
|
92
|
+
meet the following conditions:
|
93
|
+
|
94
|
+
(a) You must give any other recipients of the Work or
|
95
|
+
Derivative Works a copy of this License; and
|
96
|
+
|
97
|
+
(b) You must cause any modified files to carry prominent notices
|
98
|
+
stating that You changed the files; and
|
99
|
+
|
100
|
+
(c) You must retain, in the Source form of any Derivative Works
|
101
|
+
that You distribute, all copyright, patent, trademark, and
|
102
|
+
attribution notices from the Source form of the Work,
|
103
|
+
excluding those notices that do not pertain to any part of
|
104
|
+
the Derivative Works; and
|
105
|
+
|
106
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
107
|
+
distribution, then any Derivative Works that You distribute must
|
108
|
+
include a readable copy of the attribution notices contained
|
109
|
+
within such NOTICE file, excluding those notices that do not
|
110
|
+
pertain to any part of the Derivative Works, in at least one
|
111
|
+
of the following places: within a NOTICE text file distributed
|
112
|
+
as part of the Derivative Works; within the Source form or
|
113
|
+
documentation, if provided along with the Derivative Works; or,
|
114
|
+
within a display generated by the Derivative Works, if and
|
115
|
+
wherever such third-party notices normally appear. The contents
|
116
|
+
of the NOTICE file are for informational purposes only and
|
117
|
+
do not modify the License. You may add Your own attribution
|
118
|
+
notices within Derivative Works that You distribute, alongside
|
119
|
+
or as an addendum to the NOTICE text from the Work, provided
|
120
|
+
that such additional attribution notices cannot be construed
|
121
|
+
as modifying the License.
|
122
|
+
|
123
|
+
You may add Your own copyright statement to Your modifications and
|
124
|
+
may provide additional or different license terms and conditions
|
125
|
+
for use, reproduction, or distribution of Your modifications, or
|
126
|
+
for any such Derivative Works as a whole, provided Your use,
|
127
|
+
reproduction, and distribution of the Work otherwise complies with
|
128
|
+
the conditions stated in this License.
|
129
|
+
|
130
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
131
|
+
any Contribution intentionally submitted for inclusion in the Work
|
132
|
+
by You to the Licensor shall be under the terms and conditions of
|
133
|
+
this License, without any additional terms or conditions.
|
134
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
135
|
+
the terms of any separate license agreement you may have executed
|
136
|
+
with Licensor regarding such Contributions.
|
137
|
+
|
138
|
+
6. Trademarks. This License does not grant permission to use the trade
|
139
|
+
names, trademarks, service marks, or product names of the Licensor,
|
140
|
+
except as required for reasonable and customary use in describing the
|
141
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
142
|
+
|
143
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
144
|
+
agreed to in writing, Licensor provides the Work (and each
|
145
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
146
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
147
|
+
implied, including, without limitation, any warranties or conditions
|
148
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
149
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
150
|
+
appropriateness of using or redistributing the Work and assume any
|
151
|
+
risks associated with Your exercise of permissions under this License.
|
152
|
+
|
153
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
154
|
+
whether in tort (including negligence), contract, or otherwise,
|
155
|
+
unless required by applicable law (such as deliberate and grossly
|
156
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
157
|
+
liable to You for damages, including any direct, indirect, special,
|
158
|
+
incidental, or consequential damages of any character arising as a
|
159
|
+
result of this License or out of the use or inability to use the
|
160
|
+
Work (including but not limited to damages for loss of goodwill,
|
161
|
+
work stoppage, computer failure or malfunction, or any and all
|
162
|
+
other commercial damages or losses), even if such Contributor
|
163
|
+
has been advised of the possibility of such damages.
|
164
|
+
|
165
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
166
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
167
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
168
|
+
or other liability obligations and/or rights consistent with this
|
169
|
+
License. However, in accepting such obligations, You may act only
|
170
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
171
|
+
of any other Contributor, and only if You agree to indemnify,
|
172
|
+
defend, and hold each Contributor harmless for any liability
|
173
|
+
incurred by, or claims asserted against, such Contributor by reason
|
174
|
+
of your accepting any such warranty or additional liability.
|
175
|
+
|
176
|
+
END OF TERMS AND CONDITIONS
|
177
|
+
|
178
|
+
APPENDIX: How to apply the Apache License to your work.
|
179
|
+
|
180
|
+
To apply the Apache License to your work, attach the following
|
181
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
182
|
+
replaced with your own identifying information. (Don't include
|
183
|
+
the brackets!) The text should be enclosed in the appropriate
|
184
|
+
comment syntax for the file format. We also recommend that a
|
185
|
+
file or class name and description of purpose be included on the
|
186
|
+
same "printed page" as the copyright notice for easier
|
187
|
+
identification within third-party archives.
|
188
|
+
|
189
|
+
Copyright 2025 Bruce McLeod
|
190
|
+
|
191
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
192
|
+
you may not use this file except in compliance with the License.
|
193
|
+
You may obtain a copy of the License at
|
194
|
+
|
195
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
196
|
+
|
197
|
+
Unless required by applicable law or agreed to in writing, software
|
198
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
199
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
200
|
+
See the License for the specific language governing permissions and
|
201
|
+
limitations under the License.
|
@@ -0,0 +1,63 @@
|
|
1
|
+
# Include project metadata files
|
2
|
+
include README.md
|
3
|
+
include LICENSE
|
4
|
+
include CLAUDE.md
|
5
|
+
include PLANNING.md
|
6
|
+
include TASK.md
|
7
|
+
|
8
|
+
# Include requirements and configuration
|
9
|
+
include requirements.txt
|
10
|
+
include pyproject.toml
|
11
|
+
include pytest.ini
|
12
|
+
include bandit.yaml
|
13
|
+
include deckbuilder-completion.bash
|
14
|
+
|
15
|
+
# Include PlaceKitten image assets
|
16
|
+
recursive-include src/placekitten/images *.png *.jpg *.jpeg
|
17
|
+
include src/placekitten/README.md
|
18
|
+
|
19
|
+
# Include template assets
|
20
|
+
recursive-include assets/templates *.pptx *.json
|
21
|
+
|
22
|
+
# Include layout intelligence data
|
23
|
+
include src/deckbuilder/layout_intelligence.json
|
24
|
+
|
25
|
+
# Include documentation
|
26
|
+
recursive-include docs *.md *.css *.html
|
27
|
+
|
28
|
+
# Include examples (will create these)
|
29
|
+
recursive-include examples *.md *.json
|
30
|
+
|
31
|
+
# Include test data and fixtures (needed for some functionality)
|
32
|
+
recursive-include tests/deckbuilder/fixtures *.json *.md
|
33
|
+
include tests/deckbuilder/test_presentation.md
|
34
|
+
include tests/deckbuilder/test_presentation.json
|
35
|
+
|
36
|
+
# Exclude unnecessary files
|
37
|
+
global-exclude *.pyc
|
38
|
+
global-exclude *.pyo
|
39
|
+
global-exclude *.pyd
|
40
|
+
global-exclude __pycache__
|
41
|
+
global-exclude .pytest_cache
|
42
|
+
global-exclude .coverage
|
43
|
+
global-exclude *.egg-info
|
44
|
+
global-exclude .DS_Store
|
45
|
+
global-exclude Thumbs.db
|
46
|
+
|
47
|
+
# Exclude development files
|
48
|
+
global-exclude .git*
|
49
|
+
global-exclude .vscode
|
50
|
+
global-exclude .idea
|
51
|
+
exclude .gitignore
|
52
|
+
exclude .pre-commit-config.yaml
|
53
|
+
|
54
|
+
# Exclude output and temporary directories
|
55
|
+
recursive-exclude output *
|
56
|
+
recursive-exclude temp *
|
57
|
+
recursive-exclude template_output *
|
58
|
+
recursive-exclude tests/deckbuilder/output *
|
59
|
+
recursive-exclude tests/placekitten/test_output *
|
60
|
+
|
61
|
+
# Exclude build artifacts
|
62
|
+
recursive-exclude dist *
|
63
|
+
recursive-exclude build *
|