Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

freebible library

Free holy bibles data and toolkit for Python developers

Project Home Page

https://github.com/neocl/freebible

Installation

freebible package is available on PyPI, so it can be installed via pip by using

pip install freebible
# or even better
python3 -m pip install freebible

Please note that freebible requires Python 3. It does not work on Python 2 anymore.

Sample code

Easy access

>>> from freebible import bibles

# Quote everything
>>> bibles.print("Gen")
[1] 創世記
[1] Genesis
>>> bibles.print("Gen", 1, 1)
[Ge 1:1] 元始に神天地を創造たまへり 
[Gen 1:1] In the beginning God created the heavens and the earth.

# Quote from a specific bible
>>> bibles.kougo.quote("John")  # this returns a book object
Book(ID='104', title='ヨハネ傳福音書', filename='John', title_eng='John', short_name='John')
>>> bibles.kougo.quote("John", 1)  # this returns a chapter object
Chapter(ID='1')
>>> bibles.kougo.quote("John", 1, 1)  # this returns a verse object
John 1:1 太初に言あり、言は神と偕にあり、言は神なりき。 

>>> bibles.web.quote("John")
Book(ID='43', title='John', filename='', title_eng='John', short_name='John')
>>> bibles.web.quote("John", 1)
Chapter(ID='1')
>>> bibles.web.quote("John", 1, 1)
John 1:1 In the beginning was the Word, and the Word was with God, and the Word was God.

Accessing Kougo

>>> from freebible import read_kougo
>>> kougo = read_kougo()
>>> print(len(kougo))
66
>>> print(kougo['John'])
[104] ヨハネ傳福音書
>>> print(len(kougo['John']))
21
>>> print(kougo['John'][1])
Chapter(ID='1')
>>> print(kougo['John'][1][1])
[John 1:1] 太初に言あり、言は神と偕にあり、言は神なりき。

Accessing World English Bible (WEB)

>>> from freebible import read_web
>>> web = read_web()
>>> print(len(web))
66
>>> print(web['John'])
[43] John
>>> print(len(web['John']))
21
>>> print(web['John'][1])
Chapter(ID='1')
>>> print(len(web['John'][1]))
51
>>> print(web['John'][1][1])
[John 1:1] In the beginning was the Word, and the Word was with God, and the Word was God.

Developer setup

If you want to contribute to the source code, you can setup the development environment like this

# Create a virtual environment to install packages
python3 -venv ~/.envfreebible
# Activate the virtual environment
. ~/.envfreebible/bin/activate

# Check out the source code to your machine
git clone https://github.com/freebible freebible-project
cd freebible-project
# Install required packages
python3 -m pip install -r requirements.txt

# Run the demo to make sure that this source code work
python3 demo.py

Bible sources:

Japanese Colloquial 口語訳: http://jco.ibibles.net/

World English Bible: https://github.com/scrollmapper/bible_databases

Metadata

Release files for freebible 0.1a8

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

Source distribution (sdist)

Source distribution for freebible 0.1a8
File Size Uploaded Provenance Actions
freebible-0.1a8.tar.gz 3.0 MB Without provenance Details for freebible-0.1a8.tar.gz

Release files / freebible-0.1a8.tar.gz

Download URL freebible-0.1a8.tar.gz
Size 3.0 MB
Tags Source
SHA-256 checksum
How to use checksums
93c0ce7c5614d6a33c2106fcf57580d74034ec3fd3c6a18dd1a2b701a0257c57
BLAKE2b-256 checksum
How to use checksums
add8ccd2a402e11b6be5cf3dc668db76ab40232d50bc318993dfffc55f0a2de2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.18.4 setuptools/41.0.1 requests-toolbelt/0.8.0 tqdm/4.19.5 CPython/3.6.8

Security for freebible 0.1a8

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.

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