Skip to main content

freeai-utils

freeai-utils Python Version

Freeai-Utils is a lightweight Python library that puts the power of popular AI models right in your hands. No external binaries, no convoluted setup. Just clean, readable code.

🚀 Small and Mighty Models: Models are smartly chosen between 81–242M parameters, fast enough for real-time use, accurate enough for tasks.

✍️ No More Boilerplate: Hate writing boilerplate or messing with low-level APIs? Just use the built-in defaults or customize them when needed.

⬇️ One setup command, then offline: After a single setup command, "freeai-utils setup -y". all models are cached locally. Your entire toolkit then runs offline, no internet required.

Note: This library focuses on being simple to use, even if it means sacrificing accuracy. It's great for beginners or anyone who wants to explore AI features without dealing with complex code. Just call the functions, it handles the rest.

📚 Table of Contents

Features

  • Audio: record WAV/MP3 (fixed, toggle, silence-triggered)
  • Audio-to-Text: OpenAI Whisper transcription & language detection
  • Speech-to-Text: Using Vosk models for real-time transcription from a microphone
  • Web Search: scrape Google results
  • Image: caption generation & OCR (EasyOCR)
  • TTS: text-to-speech via gTTS or pyttsx3
  • PDF-DOCX-Reader: extract text and images from pdf and docx files
  • Document Filter: extract and rank relevant content from documents using an extractive QA model
  • Translator: Provides automatic language detection, translating content into your specified target language. (both online and local)
  • LocalLLM: Small Qwen model for offline use or as a chatbot without an API key.
  • ImageGenerator: Easy interaction with SDXL Turbo and SD1.5 models for image generation (for UI and performance, consider using AUTOMATIC1111)
  • Gemini API: Interact with Google Cloud Gemini models via your API key

    • Note: This works best with Google accounts that have no billing method added yet (completely free to use with limits).

Installation

Before installing freeai-utils, you need to install PyTorch manually based on your system and desired configuration (CPU or CUDA).

🔧 Prerequisite: Install PyTorch

Visit the official PyTorch installation guide:

👉 https://pytorch.org/get-started/locally

Choose your system (OS, package manager, Python version, CUDA version), and copy the appropriate install command.

📦 Install freeai-utils

pip install freeai-utils
  • Install Dependencies related to AI Features :
    freeai-utils install-deps ai
    

No need to install extra executables or clone large repositories — everything works out of the box with pip.


📝Models download

freeai-utils setup
# Will ask you for confirmation

freeai-utils setup -y
# Will skip confirmation prompt

This will help downloads default models for most functional classes (excluding image generation).

For 🎨 image generation models:

freeai-utils setup ICF

For more detailed control over which models to download:

freeai-utils help

This will displays a list of setup options for specific model types. You can also trigger downloads programmatically by instantiating the relevant class.

🚀 Optional GPU Performance Boost

For GPU users, if you want to take advantage of faster attention using xformers, install it separately (remember to choose it base on your system and your cuda version): https://github.com/facebookresearch/xformers

📖 Full API Reference

For a detailed list of all classes and methods, see API.md.

Acknowledgements & References

See THIRD_PARTY.md for a full list of third-party libraries and their licenses.

Inspiration

This project was inspired by the GitHub repository: awesome-python

License

This project is licensed under the MIT License - see the LICENSE file for details.

Test Environment

This library has been tested on laptop with the following specifications:

CPU: Intel Core i5-12500H GPU: NVIDIA GeForce RTX 3050 4GB GDDR6 RAM: 32GB DDR4 OS: Windows 11 Home 64-bit CUDA Version: CUDA 12.6

Performance may vary depending on system specs. The selected models and safetensors were intentionally chosen to remain lightweight. All features, including image generation have been tested to run smoothly on GPUs with just 4GB of VRAM, such as the RTX 3050.

Metadata

Release files for freeai-utils 0.6.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for freeai-utils 0.6.4
File Size Uploaded
freeai_utils-0.6.4.tar.gz 70.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for freeai-utils 0.6.4
File Interpreter ABI Platform
freeai_utils-0.6.4-py3-none-any.whl Python 3 none any Details

Total release size: 140.1 kB

Release files / freeai_utils-0.6.4.tar.gz

Download URL freeai_utils-0.6.4.tar.gz
Size 70.1 kB
Tags Source
SHA-256 checksum
How to use checksums
2f9d84623169e3d331cbc1f0dd2b429774113cc6569f1e7662b902b17f7aefce
BLAKE2b-256 checksum
How to use checksums
1bc7517bb0e25cc4aca539eacd371819d3ac3f0dacbddb480788243631b7d624
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.6

Release files / freeai_utils-0.6.4-py3-none-any.whl

Download URL freeai_utils-0.6.4-py3-none-any.whl
Size 70.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
18320c613aec3f1460c3875354cb8e367a6c2c0fa67967c235e22825de7794ee
BLAKE2b-256 checksum
How to use checksums
038abd30140934790799fd1256f28d6bf4c856fc9e6ae1cef8b974f67716cb1e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.6

Release history Release notifications | RSS feed

This release

0.6.4 This release

2 release files

0.6.3

2 release files

0.6.2

2 release files

0.6.1

1 release file

0.6.0

2 release files

0.5.15

2 release files

0.5.13

2 release files

0.5.12

2 release files

0.5.11

2 release files

0.5.10

2 release files

0.5.9

2 release files

0.5.8

2 release files

0.5.7

2 release files

0.5.6

2 release files

0.5.5

2 release files

0.5.4

2 release files

0.5.3

2 release files

0.5.2

2 release files

0.5.1

2 release files

0.5.0

2 release files

0.4.6

2 release files

0.4.5

2 release files

0.4.4

2 release files

0.4.3

2 release files

0.4.2

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.6

2 release files

0.3.5

2 release files

0.3.4

2 release files

0.3.3

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.12

2 release files

0.2.11

2 release files

0.2.10

2 release files

0.2.9

2 release files

0.2.8

2 release files

0.2.7

2 release files

0.2.6

2 release files

0.2.5

2 release files

0.2.4

2 release files

0.2.3

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page