Metadata-Version: 2.4
Name: nbforge
Version: 0.1.0
Summary: Convert Jupyter notebooks into structured Python projects , Streamlit app or FastAPI app.
Author-email: Ankit Das <ankitdas.cg22@gmail.com>
License: MIT
Requires-Python: >=3.8
Description-Content-Type: text/markdown
Requires-Dist: aiohappyeyeballs>=2.6.1
Requires-Dist: aiohttp>=3.11.18
Requires-Dist: aiosignal>=1.3.2
Requires-Dist: annotated-types>=0.7.0
Requires-Dist: anyio>=4.9.0
Requires-Dist: async-timeout>=5.0.1
Requires-Dist: attrs>=25.3.0
Requires-Dist: certifi>=2025.4.26
Requires-Dist: charset-normalizer>=3.4.1
Requires-Dist: click>=8.1.8
Requires-Dist: dataclasses-json>=0.6.7
Requires-Dist: distro>=1.9.0
Requires-Dist: exceptiongroup>=1.2.2
Requires-Dist: fastjsonschema>=2.21.1
Requires-Dist: frozenlist>=1.6.0
Requires-Dist: greenlet>=3.2.1
Requires-Dist: groq>=0.23.1
Requires-Dist: h11>=0.16.0
Requires-Dist: httpcore>=1.0.9
Requires-Dist: httpx>=0.28.1
Requires-Dist: httpx-sse>=0.4.0
Requires-Dist: idna>=3.10
Requires-Dist: jsonpatch>=1.33
Requires-Dist: jsonpointer>=3.0.0
Requires-Dist: jsonschema>=4.23.0
Requires-Dist: jsonschema-specifications>=2025.4.1
Requires-Dist: jupyter_core>=5.7.2
Requires-Dist: langchain>=0.3.24
Requires-Dist: langchain-community>=0.3.22
Requires-Dist: langchain-core>=0.3.56
Requires-Dist: langchain-groq>=0.3.2
Requires-Dist: langchain-text-splitters>=0.3.8
Requires-Dist: langsmith>=0.3.37
Requires-Dist: marshmallow>=3.26.1
Requires-Dist: multidict>=6.4.3
Requires-Dist: mypy_extensions>=1.1.0
Requires-Dist: nbformat>=5.10.4
Requires-Dist: numpy>=2.2.5
Requires-Dist: orjson>=3.10.16
Requires-Dist: packaging>=24.2
Requires-Dist: platformdirs>=4.3.7
Requires-Dist: propcache>=0.3.1
Requires-Dist: pydantic>=2.11.3
Requires-Dist: pydantic-settings>=2.9.1
Requires-Dist: pydantic_core>=2.33.1
Requires-Dist: python-dotenv>=1.1.0
Requires-Dist: PyYAML>=6.0.2
Requires-Dist: referencing>=0.36.2
Requires-Dist: requests>=2.32.3
Requires-Dist: requests-toolbelt>=1.0.0
Requires-Dist: rpds-py>=0.24.0
Requires-Dist: sniffio>=1.3.1
Requires-Dist: SQLAlchemy>=2.0.40
Requires-Dist: tenacity>=9.1.2
Requires-Dist: traitlets>=5.14.3
Requires-Dist: typing-inspect>=0.9.0
Requires-Dist: typing-inspection>=0.4.0
Requires-Dist: typing_extensions>=4.13.2
Requires-Dist: urllib3>=2.4.0
Requires-Dist: yarl>=1.20.0
Requires-Dist: zstandard>=0.23.0

# NBForge

- Python package to convert notebooks into well structured python projects .
- Goal is to be able to process notebooks to

  - 1. Create python project with well structured modules
  - 2. Create FAST-API wrapper
  - 3. Create Streamlit frontend

- Modes of offering

  - 1. Webapp - drop the jupyter notebook and forge the project you want
  - 2. CLI
  - 3. VS-Code extension

- Milestones :

- 1. convert notebook to python project -- done
- 2. stream lit -- done
  - to provide stream lit desc create a markdown with the header `NBForge_Streamlit`
  - if there are multiple such markdown blocks we pick the latest one
- 3. fast api support -- DONE
- 4. proper structure - DONE 
  - add description for each function -- DONE 
- 5. update toml file -- DONE 
  - optimze (remove unnecessary dependencies)
- 5. setup logging -- DONE 
  - add proper logging to each file -- ADDED TO converter.py , rest not adding 
- 6. proper packaging (toml) -- DONE 
- 7. format the files -- DONE 
- 8. convert to package [ IMP ] -- DONE
  - understand difference between  
    - a. publishing a package that one can import
    - b. publishing a pakcage that people install and use in cli
- 9. cli -- DONE 
optimze (remove unnecessary dependencies)
- 10. publish to pypi
- 11. webapp
- 12. vs code extension

- MAYBE : we will provide an option to create test cases for the modules
- add anotations :

  - through comments probably
  - user can state whether to add this markdown as comment or as as main readme

- if we are offering as cli then how to use the groq api key?

### Tasks

- revamp the prompt

  - make sure llm does not add anything of its own
  - it just goes over the code and separates the code and comments
  - should we allow it to revamp the comments and readme?

- check the streamlit app . check whether it is correctly picking the csv file .
- test the demo MSE calculation program with all 3

  - default modules
  - stream lit
  - fast api

- Sample image from streamlit app generated using this package
- ![alt text](./images/streamlit_1.png)
- ![alt text](./images/streamlit_2.png)

- Sample endpoint from fastAPI app generated using this package
- ![alt text](./images/fastapi_1.png)

## CLI tool
- Run the following command to covnert the jupyter notebook file at `NOTEBOOK_PATH` into a python module created in directory `OUTPUT_DIRECTORY`.
```bash
$ nbforge convert <NOTEBOOK_PATH> <OUTPUT_DIRECTORY>
```
