PyCForge
PyCForge is a focused Python-to-C source transpiler with a complete desktop workspace, command-line tools, and a Python API. It converts its documented, typed Python subset into readable C11 source. Unsupported input is rejected with clear diagnostics instead of being guessed or silently changed.
Install, upgrade, and open
PyCForge requires Python 3.11 or newer. PySide6 and the complete desktop application are installed automatically.
On Windows, install PyCForge and open the workspace with:
py -m pip install pycforge
py -m pycforge.ide
To upgrade an existing Windows installation and open it immediately:
py -m pip install --upgrade pycforge
py -m pycforge.ide
On macOS or Linux:
python -m pip install pycforge
python -m pycforge.ide
To upgrade on macOS or Linux:
python -m pip install --upgrade pycforge
python -m pycforge.ide
py -m pycforge.ide is the easiest Windows launch command because it works
immediately after either installation or upgrade. The installed
pycforge-workspace command opens the same application.
What PyCForge provides
- A professional dark desktop workspace for opening, editing, organizing, and transpiling Python source bundles of up to 64 files.
- Side-by-side Python and generated C, with exact ForgeLens navigation between corresponding source locations.
- Tabs, split source view, function folding, outline, search and replace, command palette, conversion history, and remembered workspace sessions.
- Read-only generated C with diagnostics, mappings, conversion summaries, decision traces, and optional telemetry views.
- Cancellable background transpilation that keeps the interface responsive.
- Deterministic output for the same source bundle and settings.
- Clear rejection of Python outside the supported conversion boundary.
- A headless command-line interface and a structured Python API for automation.
- Independent Python and generated-C text sizing, accessible controls, and display-aware window sizing.
- Searchable documentation built directly into the application.
PyCForge currently supports selected typed functions, scalar expressions, conditionals, bounded loops, direct calls, fixed containers and records, fixed-set membership, explicit module bundles, and a bounded UTF-8 file I/O profile. The in-app documentation gives the exact accepted and rejected forms.
Ting agent integration
PyCForge includes six deterministic Ting agents that examine each completed or rejected conversion from different engineering perspectives:
- syntax admission;
- semantic preservation;
- ownership and lifetime;
- C lowering readiness;
- release verification; and
- capability and resource limits.
The Ting agents use authenticated local rulepacks and bounded work limits. They receive structural evidence rather than source text, run without a network connection, and report their evidence and gaps in a dedicated read-only feedback window.
Ting currently operates in shadow evaluation mode. Its feedback can help review a conversion, but it never changes, approves, blocks, or publishes the generated C.
Built-in help and documentation
Press F1 or choose Help → PyCForge Help… to open 14 searchable offline
help pages. They cover the workspace, supported Python, generated C, Ting
feedback, diagnostics, safety limits, shortcuts, the CLI, and the Python API.
No browser or network connection is required. The source distribution also
includes PyCForge_v0_16_0_Programmers_Conversion_Guide.pdf.
Command line
Convert a Python file to C:
pycforge convert input.py --output generated.c
Return the structured conversion result as JSON:
pycforge --format json convert input.py
See every command and option:
pycforge --help
Python API
from pycforge import ConversionRequest, PythonToCConverter
source = """\
def add(left: int, right: int) -> int:
return left + right
"""
result = PythonToCConverter().convert(
ConversionRequest.from_source(source)
)
if result.generated_c is not None:
print(result.generated_c)
else:
for diagnostic in result.diagnostics:
print(diagnostic)
The desktop workspace, CLI, and Python API use the same converter.
Safety boundary
PyCForge reads supplied Python as source data. It does not import or execute that Python, and it does not compile, link, load, or run the generated C. Review the built-in Safety and limits page before using generated code in another build system.
PyCForge 1.0.2
Version 1.0.2 presents a shorter feature-focused README with current workspace and Ting feedback images. It also makes the close control in the top notification banner follow the notification's information, success, warning, or error color while leaving the rest of the reviewed interface unchanged.
License
PyCForge is free software released under the GNU General Public License v3.0
only. The complete license text is included in LICENSE.
Release files for pycforge 1.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pycforge-1.0.2.tar.gz | 3.6 MB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pycforge-1.0.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 4.4 MB
Release files / pycforge-1.0.2.tar.gz
| Download URL | pycforge-1.0.2.tar.gz |
|---|---|
| Size | 3.6 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2b492914f66bc81b142df2e05c399a58b757cfb115c4195566f027c1eecd23e8
|
|
BLAKE2b-256 checksum How to use checksums |
138fd43daabb410798dfb225b0c78a23eac416d3afa37ce2541e333ffb464e8a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/0.0.0 importlib_metadata/4.0.1 pkginfo/1.12.1.2 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.1 CPython/3.9.16
|
Release files / pycforge-1.0.2-py3-none-any.whl
| Download URL | pycforge-1.0.2-py3-none-any.whl |
|---|---|
| Size | 806.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d0d5b0ad65f7791a8cd69185329a71b34e6053a9ad2ac95bf0f3ae619ec6f95d
|
|
BLAKE2b-256 checksum How to use checksums |
ec521ee332bddab1eb59a41121cdeff63677770381f38a898211a1c9ca0d0885
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/0.0.0 importlib_metadata/4.0.1 pkginfo/1.12.1.2 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.1 CPython/3.9.16
|