kimhyunwoo commited on
Commit
9dd9ecc
ยท
verified ยท
1 Parent(s): f6db0a9

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +78 -5
README.md CHANGED
@@ -1,13 +1,86 @@
1
  ---
2
- title: C
3
- emoji: ๐Ÿ‘€
4
  colorFrom: green
5
  colorTo: gray
6
  sdk: gradio
7
- sdk_version: 5.33.0
8
  app_file: app.py
9
- pinned: false
10
  license: mit
 
 
 
11
  ---
12
 
13
- Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+ title: C-Codestral Agent
3
+ emoji: ๐Ÿค–
4
  colorFrom: green
5
  colorTo: gray
6
  sdk: gradio
7
+ sdk_version: 4.31.0 # langchain๊ณผ ํ˜ธํ™˜์„ฑ์„ ์œ„ํ•ด 4.x ๋ฒ„์ „์„ ๋ช…์‹œํ•˜๋Š” ๊ฒƒ์ด ์•ˆ์ •์ ์ผ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.
8
  app_file: app.py
9
+ pinned: true
10
  license: mit
11
+ tags:
12
+ - agent-demo-track
13
+ - mcp-server-track
14
  ---
15
 
16
+ # ๐Ÿš€ C-Codestral Agent: Your C-Language Co-pilot
17
+
18
+ **C-Codestral Agent** is a powerful, conversational AI agent designed to assist developers with C programming. Powered by Mistral's `Codestral` model and built with Gradio and LangChain, this agent can generate, analyze, refactor, compile, and run C code seamlessly within a single interface.
19
+
20
+ This project is a submission for the **Agents & MCP Hackathon 2025**, demonstrating the power of AI agents and the Model Context Protocol (MCP).
21
+
22
+ [![Gradio App](https://img.shields.io/badge/Gradio-App-blue)](https://huggingface.co/spaces/Agents-MCP-Hackathon/c) <!-- ์ด ๋ถ€๋ถ„์€ ์‹ค์ œ Space URL๋กœ ์ž๋™ ์—ฐ๊ฒฐ๋ฉ๋‹ˆ๋‹ค -->
23
+
24
+ ---
25
+
26
+ ## ๐ŸŽฅ Demo Video
27
+
28
+ Here is a short video demonstrating the core functionalities of the C-Codestral Agent, including code generation, compilation, and its use as an MCP tool.
29
+
30
+ **(ใ“ใ“ใซใƒ‡ใƒขใƒ“ใƒ‡ใ‚ชใธใฎใƒชใƒณใ‚ฏใ‚’ๆŒฟๅ…ฅใ—ใฆใใ ใ•ใ„ใ€‚ไพ‹: [Watch the Demo on YouTube](https://youtu.be/your_video_id))**
31
+
32
+ *์ค‘์š”: ๋ฐ๋ชจ ์˜์ƒ ๋งํฌ๋ฅผ ์—ฌ๊ธฐ์— ๊ผญ ์ถ”๊ฐ€ํ•˜์„ธ์š”. Loom, YouTube, ๋˜๋Š” Space์— ์ง์ ‘ ์—…๋กœ๋“œํ•œ ์˜์ƒ ๋งํฌ๋„ ์ข‹์Šต๋‹ˆ๋‹ค.*
33
+
34
+ ---
35
+
36
+ ## โœจ Core Features
37
+
38
+ * **๐Ÿค– Conversational Code Generation**: Simply ask the agent in natural language to create C code for any task, from simple "Hello, World!" programs to complex algorithms.
39
+ * **โœ… Instant Compilation & Execution**: Test the generated or provided C code immediately. The agent uses a secure backend with `gcc` to compile and run the code, showing you the output or any errors in real-time.
40
+ * **๐Ÿง  Intelligent Code Analysis & Refactoring**: Provide your existing C code and ask for improvements, optimizations, or explanations. The agent helps you write better, more efficient code.
41
+ * **๐Ÿ› ๏ธ MCP-Enabled Tools**: The agent's core capabilities (generate, compile, refactor) are exposed as MCP-compliant tools. This allows other LLM agents (like Claude Desktop, Cursor, etc.) to use this Gradio Space as a powerful C programming "tool" to solve complex problems.
42
+
43
+ ---
44
+
45
+ ## ๐Ÿ› ๏ธ Tech Stack & Architecture
46
+
47
+ This project integrates several cutting-edge technologies to create a robust agentic system:
48
+
49
+ * **LLM (The Brain)**: `codestral-latest` by Mistral AI for its state-of-the-art code generation and understanding capabilities.
50
+ * **Agent Framework**: `LangChain` to orchestrate the agent's logic, manage conversation history, and intelligently decide which tool to use.
51
+ * **Frontend & UI**: `Gradio` for creating a sleek, responsive, and interactive chat interface.
52
+ * **Backend & Execution Environment**: Hugging Face Spaces, utilizing a secure Linux container with `gcc` for C code compilation.
53
+ * **Tool Protocol**: Model Context Protocol (MCP) via Gradio's `@tool` and `gr.load_tools()` functionalities, making the agent's skills available to the wider AI ecosystem.
54
+
55
+ <p align="center">
56
+ <img src="https://i.imgur.com/your_architecture_diagram_url.png" width="700">
57
+ <em>(์„ ํƒ ์‚ฌํ•ญ: ์•„ํ‚คํ…์ฒ˜ ๋‹ค์ด์–ด๊ทธ๋žจ ์ด๋ฏธ์ง€๋ฅผ ์ถ”๊ฐ€ํ•˜๋ฉด ์ „๋ฌธ์„ฑ์„ ๋”ํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.)</em>
58
+ </p>
59
+
60
+ ---
61
+
62
+ ## ๐Ÿš€ How to Use
63
+
64
+ 1. **Chat with the Agent**: Open the Gradio app and start a conversation. You can ask it to:
65
+ * `"Generate a C program to find all prime numbers up to 100."`
66
+ * `(After code is generated) "Now, compile and run it."`
67
+ * `(Paste your code) "Refactor this code to be more memory-efficient."`
68
+
69
+ 2. **Use as an MCP Tool**:
70
+ * Connect your favorite MCP client (e.g., a compatible version of Claude Desktop).
71
+ * Add this Hugging Face Space as a tool.
72
+ * You can now ask the client to perform C-related tasks, and it will use this agent's tools (`generate_c_code`, `compile_and_run_c_code`, etc.) to get the job done.
73
+
74
+ ---
75
+
76
+ ## ๐Ÿ† Hackathon Submission Details
77
+
78
+ This project is submitted for the following tracks and awards:
79
+
80
+ * **Primary Track**: `agent-demo-track`
81
+ * **Secondary Track**: `mcp-server-track`
82
+ * **Hoping to be considered for**:
83
+ * Most Innovative Use of MCP Award
84
+ * Community Choice Award
85
+
86
+ Thank you for checking out our project!