AbuLang - Natural Language Programming
AbuLang is a natural-language programming language that makes coding intuitive and accessible. It translates human-readable syntax into Python, making programming easier for beginners and creative coders.
Features
- Natural Language Syntax: Write code that reads like English
- Python Integration: All AbuLang commands work natively in Python IDLE
- GUI Support: Built-in GUI manager for creating interactive applications
- 3D Graphics: Support for 3D scene creation and manipulation
- File Operations: Easy file reading, writing, and manipulation
- Data Storage: In-memory storage similar to browser localStorage
- Text Processing: Advanced text matching, encoding, and manipulation
- Game Development: Physics engine with gravity simulation
- Web Support: Browser-based IDE with Pyodide integration
Installation
pip install AbuLang
Quick Start
Using AbuLang in Python IDLE
from AbuLangModule import enable_abulang
enable_abulang()
show "Hello, World!"
name = ask "What is your name?"
show "Nice to meet you, " + name
Using the AbuLang Interpreter
Create a file script.abu:
show "Hello, World!"
name = ask "What is your name?"
show "Nice to meet you, " + name
Run it:
python -m AbuLangModule.interpreter script.abu
Core Commands
I/O Commands
show(...)- Display outputask(prompt)- Get user inputmultiple_choice_terminal(prompt, options)- Show multiple choice menu
Data Storage
Create DataStorage as varname- Create isolated in-memory storage- Methods:
setItem(key, value),getItem(key),removeItem(key),clear() - Property:
length
- Methods:
Math Commands
plus(a, b)- Add numbersminus(a, b)- Subtract numbersmulti(a, b)- Multiply numbersdivid(a, b)- Divide numbersexpon(a, b)- Power (a^b)modul(a, b)- Modulo (a%b)absof(x)- Absolute valuesumup(list)- Sum of listavera(list)- Average of list
String Commands
strip(text)- Remove spaceslower(text)- Lowercaseupper(text)- Uppercasereplc(text, old, new)- Replace textfindt(text, word)- Find substringlengt(text)- Lengthisolate(filter, list)- Filter list by string
File Commands
readf(file)- Read filewrite(file, text)- Write fileget_line(n, file)- Get line N from filesave_as(file)- Save format buffer to file
GUI Commands
gui_create(width, height, title)- Create GUI windowobj_create(manager, shape, top_left, bottom_right)- Create objectrgb(r, g, b)- Convert RGB to hex color
Advanced Features
- Text Matching:
match(text, pattern)- Match text case to pattern - Cipher/Decipher:
cipher(text, pattern),decipher(text)- Encode/decode text - Image Processing:
move_to_replicate(gui, image_file, scale, pixel_size)- Convert image to pixel art - Physics:
on_earth(),on_moon(),on_jupiter()- Set gravity types - 3D Graphics:
lib_3d()- Import 3D library
DataStorage Example
from AbuLangModule import enable_abulang
enable_abulang()
# Create a DataStorage instance
Create DataStorage as db
# Store data
db.setItem("username", "Abu")
db.setItem("email", "abu@example.com")
# Retrieve data
show db.getItem("username")
show db.length
GUI Example
from AbuLangModule import enable_abulang
enable_abulang()
libra("abui")
# Create a GUI window
gui = gui_create(800, 600, "My App")
# Create objects
rect = obj_create(gui, "rect", (10, 10), (100, 100))
rect.set_color(rgb(255, 0, 0), "black")
# Run the GUI
gui.run()
Documentation
For more detailed documentation, see:
Requirements
- Python 3.8+
- PyYAML >= 5.4
Optional Dependencies
For full features:
pip install AbuLang[full]
For chess AI:
pip install AbuLang[chess]
License
MIT License
Author
Abu
Support
For issues, questions, or suggestions, please visit the project repository.
Metadata
Release files for AbuLang 4.12.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| abulang-4.12.0.tar.gz | 29.0 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| abulang-4.12.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 58.7 kB
Release files / abulang-4.12.0.tar.gz
| Download URL | abulang-4.12.0.tar.gz |
|---|---|
| Size | 29.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2042e093dfe1889793258ce508df0c1590b8d99ffc103943444433fdd1e0d065
|
|
BLAKE2b-256 checksum How to use checksums |
8257659a9081d7da8f8aebe8256b095d36ab994db613b69b53b9965eb5b4fc28
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.5
|
Release files / abulang-4.12.0-py3-none-any.whl
| Download URL | abulang-4.12.0-py3-none-any.whl |
|---|---|
| Size | 29.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
269a77c0cd1b97a7a5385b3c475ef160facf3185caebb8657077ff79e2be0f7a
|
|
BLAKE2b-256 checksum How to use checksums |
7fe64555a4dc5873b164e0b7556a44b834c9c8007f166dd12b4356484137f819
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.5
|
Security for AbuLang 4.12.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.