# What Programming Languages Are Used in Open Notebook? A Full-Stack Breakdown

> Discover the programming languages powering Open Notebook: TypeScript for React, Python 3.11+ for FastAPI, and Bash/Docker for deployment. Get a full-stack breakdown.

- Repository: [Luis Novo/open-notebook](https://github.com/lfnovo/open-notebook)
- Tags: tutorial
- Published: 2026-07-03

---

**Open Notebook is built with TypeScript for the React frontend, Python 3.11+ for the FastAPI backend, and Bash/Docker for deployment automation.**

Open Notebook is a full-stack AI notebook application that leverages a polyglot architecture to separate concerns across the UI, API, and infrastructure layers. The codebase strategically employs three distinct programming languages to optimize for type safety, async performance, and developer experience. Understanding the programming languages used in Open Notebook reveals how modern open-source projects combine the best of JavaScript and Python ecosystems.

## Frontend: TypeScript with React and Next.js

The user interface layer relies entirely on **TypeScript** to provide compile-time type safety for the React component tree. All frontend source code resides in the `frontend/` directory, where JSX components coexist with Zustand state management and Tailwind CSS styling.

### Key TypeScript Configuration Files

The project's TypeScript compiler settings are defined in [`frontend/tsconfig.json`](https://github.com/lfnovo/open-notebook/blob/main/frontend/tsconfig.json), which enforces strict type checking for the React ecosystem. Dependencies are managed through [`frontend/package.json`](https://github.com/lfnovo/open-notebook/blob/main/frontend/package.json), which lists Next.js, React, and TypeScript as core dependencies.

```tsx
// File: frontend/src/components/ui/Hello.tsx
import React from "react";

type Props = {
  name?: string;
};

export const Hello: React.FC<Props> = ({ name = "world" }) => (
  <div className="p-4 text-lg">
    Hello, {name}!
  </div>
);

```

*Source:* This pattern mirrors the implementation found in [[`frontend/src/components/ui/button.tsx`](https://github.com/lfnovo/open-notebook/blob/main/frontend/src/components/ui/button.tsx)](https://github.com/lfnovo/open-notebook/blob/main/frontend/src/components/ui/button.tsx), demonstrating the type-safe component architecture used throughout the UI layer.

## Backend: Python 3.11+ with FastAPI

The API layer is implemented entirely in **Python 3.11+**, utilizing FastAPI's async capabilities to orchestrate AI providers and LangGraph workflows. According to the `lfnovo/open-notebook` source code, the backend handles heavy computational tasks including multi-provider AI abstraction and SurrealDB graph database operations.

### Core Python Modules

The FastAPI application initialization occurs in [`api/main.py`](https://github.com/lfnovo/open-notebook/blob/main/api/main.py), where the app instance is configured with CORS middleware and router inclusion. Business logic is modularized across [`open_notebook/ai/models.py`](https://github.com/lfnovo/open-notebook/blob/main/open_notebook/ai/models.py) (AI provider abstraction) and [`open_notebook/database/repository.py`](https://github.com/lfnovo/open-notebook/blob/main/open_notebook/database/repository.py) (async database access).

```python

# File: api/main.py

from fastapi import FastAPI

app = FastAPI(title="Open Notebook API")

@app.get("/hello")
async def hello(name: str = "world"):
    """Return a friendly greeting."""
    return {"message": f"Hello, {name}!"}

```

*Source:* The full FastAPI implementation in [[`api/main.py`](https://github.com/lfnovo/open-notebook/blob/main/api/main.py)](https://github.com/lfnovo/open-notebook/blob/main/api/main.py) uses this same pattern for endpoint definition and middleware configuration.

## DevOps and Infrastructure: Bash and Docker

Deployment automation and development tooling utilize **Bash** shell scripts and **Docker** declarative syntax. These languages handle container orchestration and CI/CD workflows rather than application business logic.

### Deployment Scripts and Containerization

The [`scripts/wait-for-api.sh`](https://github.com/lfnovo/open-notebook/blob/main/scripts/wait-for-api.sh) file provides a health-check utility written in Bash, while the root-level `Dockerfile` defines the container image packaging the Python runtime. Utility scripts like [`scripts/export_docs.py`](https://github.com/lfnovo/open-notebook/blob/main/scripts/export_docs.py) demonstrate Python's secondary role in development tooling.

```bash
#!/usr/bin/env bash

# wait for the API to become healthy before proceeding

while ! curl -s http://localhost:5055/health | grep -q "healthy"; do
  echo "Waiting for API..."
  sleep 1
done

echo "API is ready!"

```

*Source:* See the production health-check implementation in [[`scripts/wait-for-api.sh`](https://github.com/lfnovo/open-notebook/blob/main/scripts/wait-for-api.sh)](https://github.com/lfnovo/open-notebook/blob/main/scripts/wait-for-api.sh).

## Summary

- **TypeScript** powers the React frontend in `frontend/`, providing type-safe UI components and Zustand state management
- **Python 3.11+** drives the FastAPI backend in `api/` and `open_notebook/`, handling AI orchestration via LangGraph and SurrealDB operations
- **Bash and Docker** automate deployment via `scripts/` and root-level container definitions
- Key configuration files include [`frontend/tsconfig.json`](https://github.com/lfnovo/open-notebook/blob/main/frontend/tsconfig.json) for TypeScript compilation and [`api/main.py`](https://github.com/lfnovo/open-notebook/blob/main/api/main.py) for FastAPI initialization
- The repository demonstrates a clean separation between frontend TypeScript code and backend Python modules

## Frequently Asked Questions

### Is Open Notebook primarily a TypeScript or Python project?

Open Notebook is both. The frontend is exclusively built with TypeScript and React, while the backend is implemented in Python using FastAPI. This split architecture allows the project to leverage TypeScript's compile-time type safety for UI development while utilizing Python's robust ecosystem for AI processing and async database operations.

### What version of Python does Open Notebook require?

The backend requires **Python 3.11 or newer**. This version requirement supports the async/await patterns used throughout [`open_notebook/database/repository.py`](https://github.com/lfnovo/open-notebook/blob/main/open_notebook/database/repository.py) and the modern FastAPI implementation found in [`api/main.py`](https://github.com/lfnovo/open-notebook/blob/main/api/main.py).

### Does Open Notebook use JavaScript or TypeScript for the frontend?

The frontend exclusively uses **TypeScript**, not plain JavaScript. Evidence includes the [`tsconfig.json`](https://github.com/lfnovo/open-notebook/blob/main/tsconfig.json) configuration file in the `frontend/` directory and the `.tsx` extension used for React components such as [`frontend/src/components/ui/button.tsx`](https://github.com/lfnovo/open-notebook/blob/main/frontend/src/components/ui/button.tsx).

### Where is the database logic implemented in Open Notebook?

Database logic is implemented in **Python** within the [`open_notebook/database/repository.py`](https://github.com/lfnovo/open-notebook/blob/main/open_notebook/database/repository.py) file. This module provides async access to SurrealDB using Python's async/await syntax, as imported and utilized by the FastAPI endpoints defined in [`api/main.py`](https://github.com/lfnovo/open-notebook/blob/main/api/main.py).