VirtualOasis commited on
Commit
f0d59b8
Β·
verified Β·
1 Parent(s): 7c0bd93

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +50 -3
README.md CHANGED
@@ -1,5 +1,5 @@
1
  ---
2
- title: T2I
3
  emoji: πŸ“š
4
  colorFrom: red
5
  colorTo: pink
@@ -7,7 +7,54 @@ sdk: gradio
7
  sdk_version: 5.33.0
8
  app_file: app.py
9
  pinned: false
10
- short_description: Generates attractive readable images from text content.
 
 
 
 
 
 
 
 
11
  ---
12
 
13
- Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+ title: "StoryPage Creator: Text to Image MCP"
3
  emoji: πŸ“š
4
  colorFrom: red
5
  colorTo: pink
 
7
  sdk_version: 5.33.0
8
  app_file: app.py
9
  pinned: false
10
+ short_description: Convert long-form text into pretty, styled, readable images.
11
+ tags:
12
+ - mcp-server-track
13
+ - agent-demo-track
14
+ - text-to-image
15
+ - document-generation
16
+ - image-creation
17
+ - text-formatting
18
+ - visual-content
19
  ---
20
 
21
+ # StoryPage Creator: Your Text-to-Image Converter
22
+
23
+ This Gradio application converts any text content into a series of visually appealing, readable images. It serves as both an interactive web application and a Model Context Protocol (MCP) server, making it perfect for UI-based creation and automated workflows.
24
+
25
+ ## ✨ Features
26
+
27
+ - **Multiple Output Formats**: Provides a user-friendly image **Gallery** for instant previews and downloads, alongside a **JSON** output with base64-encoded strings for easy API integration.
28
+ - **Rich Customization**:
29
+ - **Font Family**: Choose from common fonts like Arial, Times New Roman, and more.
30
+ - **Font Size**: Use the slider to find the perfect font size for readability.
31
+ - **Aspect Ratio**: Select from standard image scales including 1:1 (Square), 16:9 (Widescreen), 9:16 (Vertical), 4:3 and 3:4.
32
+ - **Background Styles**: Add a touch of personality with `lines`, `dots`, `grid`, or a `plain` background.
33
+ - **Background Color**: Select from a palette of soft, easy-to-read background colors.
34
+ - **MCP Server Enabled**: Can be called as an API endpoint, returning structured JSON data for programmatic use.
35
+
36
+ ## πŸš€ How to Use
37
+
38
+ ### Interactive UI
39
+
40
+ 1. **Paste Text**: Enter or paste your desired text content into the text box.
41
+ 2. **Customize**: Use the controls on the left to adjust the style, font size, color, aspect ratio, and font family.
42
+ 3. **Submit**: Click the "Submit" button to generate the images.
43
+ 4. **Preview & Download**: The generated images will appear in the "Generated Images (Preview)" gallery. You can click on an image to view it in full size and use the download icon to save it.
44
+
45
+ ## 🎬 Demo
46
+
47
+ ### πŸ€– API / MCP Usage
48
+
49
+ This MCP server can be used both as a Gradio web interface and as an MCP server for AI agents. Simply provide your text content and select your preferred background style to generate formatted images, it will bypass the visual gallery and return a clean JSON object.
50
+
51
+ **Example Input**:
52
+ ```json
53
+ {
54
+ "text_content": "Your text content here...",
55
+ "style": "lines"
56
+ }
57
+ ```
58
+
59
+ **Output**: Base64-encoded PNG image(s) ready for viewing or download
60
+