<commit_before>.. include:: ../global.rst

Jedi Development
================

.. currentmodule:: jedi

.. note:: This documentation is for Jedi developers, who want to improve Jedi
    itself, but have just no idea how Jedi works. If you want to use Jedi for 
    your IDE, look at the `plugin api <plugin-api.html>`_.


Introduction
------------

This page tries to address the fundamental demand for documentation of the
|jedi| interals. Understanding a dynamic language is a complex task. Especially
because type inference in Python can be a very recursive task. Therefore |jedi|
couldn't get rid of complexity. We know that **simple is better than complex**,
but unfortunately it requires sometimes complex solutions to understand complex
systems.


In five chapters we're trying to describe the internals of |jedi|:

- :ref:`The Jedi Core <dev-core>`
- :ref:`Core Extensions <dev-extensions>`
- :ref:`Imports & Modules <dev-imports-modules>`
- :ref:`Caching & Recursions <dev-caching-recursions>`
- :ref:`Helper modules <dev-helpers>`


.. _dev-core:

The Jedi Core
-------------

The core of Jedi consists of three parts:

- :ref:`API <dev-api>`
- :ref:`Parser <dev-parser>`
- :ref:`Python code evaluation <dev-evaluate>`

.. _dev-api:

API (api.py and api_classes.py)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

API

.. _dev-parsing:

Parser (parsing.py)
~~~~~~~~~~~~~~~~~~~

.. automodule:: parsing

.. _dev-evaluate:

Evaluation of python code (evaluate.py)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

.. automodule:: evaluate



.. _dev-extensions:

Core Extensions
---------------

Docstrings (docstrings.py)
~~~~~~~~~~~~~~~~~~~~~~~~~~

.. automodule:: docstrings

Dynamic Arrays & Function Parameters (dynamic.py)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

.. automodule:: dynamic

Refactoring (docstrings.py)
~~~~~~~~~~~~~~~~~~~~~~~~~~~

.. automodule:: refactoring


.. _dev-imports-modules:



Imports & Modules
-------------------

Modules (modules.py)
~~~~~~~~~~~~~~~~~~~~

.. automodule:: modules

Builtin Modules (builtin.py)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~<commit_msg>sphinx dev: core extensions description<commit_after>.. include:: ../global.rst

Jedi Development
================

.. currentmodule:: jedi

.. note:: This documentation is for Jedi developers, who want to improve Jedi
    itself, but have just no idea how Jedi works. If you want to use Jedi for 
    your IDE, look at the `plugin api <plugin-api.html>`_.


Introduction
------------

This page tries to address the fundamental demand for documentation of the
|jedi| interals. Understanding a dynamic language is a complex task. Especially
because type inference in Python can be a very recursive task. Therefore |jedi|
couldn't get rid of complexity. We know that **simple is better than complex**,
but unfortunately it requires sometimes complex solutions to understand complex
systems.


In five chapters we're trying to describe the internals of |jedi|:

- :ref:`The Jedi Core <dev-core>`
- :ref:`Core Extensions <dev-extensions>`
- :ref:`Imports & Modules <dev-imports-modules>`
- :ref:`Caching & Recursions <dev-caching-recursions>`
- :ref:`Helper modules <dev-helpers>`


.. _dev-core:

The Jedi Core
-------------

The core of Jedi consists of three parts:

- :ref:`API <dev-api>`
- :ref:`Parser <dev-parser>`
- :ref:`Python code evaluation <dev-evaluate>`

.. _dev-api:

API (api.py and api_classes.py)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

API

.. _dev-parsing:

Parser (parsing.py)
~~~~~~~~~~~~~~~~~~~

.. automodule:: parsing

.. _dev-evaluate:

Evaluation of python code (evaluate.py)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

.. automodule:: evaluate



.. _dev-extensions:

Core Extensions
---------------

Core Extensions is a summary of the following topics:

- :ref:`Dynamic Arrays & Function Parameters <dev-dynamic>`
- :ref:`Docstrings <dev-docstrings>`
- :ref:`Refactoring <dev-refactoring>`

These topics are very important to understand what Jedi additionally does, but
they could be removed from Jedi and Jedi would still work. But logically
without refactoring support, docstrings and the understanding of the dynamic
nature of Python.


.. _dev-dynamic:

Dynamic Arrays & Function Parameters (dynamic.py)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

.. automodule:: dynamic

.. _dev-docstrings:

Docstrings (docstrings.py)
~~~~~~~~~~~~~~~~~~~~~~~~~~

.. automodule:: docstrings

.. _dev-refactoring:

Refactoring (docstrings.py)
~~~~~~~~~~~~~~~~~~~~~~~~~~~

.. automodule:: refactoring


.. _dev-imports-modules:



Imports & Modules
-------------------

Modules (modules.py)
~~~~~~~~~~~~~~~~~~~~

.. automodule:: modules

Builtin Modules (builtin.py)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
{'fraction_non_alphanumeric': 0.2259923175416133, 'fraction_numerical': 0.0, 'mean_word_length': 3.9914802981895634, 'pattern_counts': {'":': 0, '<': 24, '<?xml version=': 0, '>': 24, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6506954', 'n_tokens_mistral': 1396, 'n_tokens_neox': 1286, 'n_words': 459}