Features
Morph is a python-centric full-stack framework for building and deploying AI apps.
- Fast to start 🚀 - Allows you to get up and running with just three commands.
- Deploy and operate 🌐 - Easily deploy your AI apps and manage them in production. Managed cloud is available for user authentication and secure data connection.
- No HTML/CSS knowledge required🔰 - With Markdown-based syntax and pre-made components, you can create flexible, visually appealing designs without writing a single line of HTML or CSS.
- Customizable 🛠️ - Chain Python and SQL for advanced AI workflows. Custom CSS and custom React components are available for building tailored UI.
Quick start
- Install morph
pip install morph-data
- Create a new project
morph new
- Start dev server
morph serve
- Visit
http://localhsot:8080on browser.
How it works
Understanding the concept of developing an AI app in Morph will let you do a flying start.
- Develop the AI workflow in Python and give it an alias.
- Create an .mdx file. Each .mdx file becomes a page of your app.
- Place the component in the MDX file and specify the alias to connect to.
.
├─ pages
│ └─ index.mdx
└─ python
└─ chat.py
Building AI Apps
A little example
- Create each files in
pythonandpagesdirectories.
Python: Using Langchain to create a AI workflow.
import morph
from morph import MorphGlobalContext
from morph_lib.stream import stream_chat
from langchain_openai import ChatOpenAI
from langchain_core.messages import HumanMessage
@morph.func
def langchain_chat(context: MorphGlobalContext):
llm = ChatOpenAI(model="gpt-4o")
messages = [HumanMessage(context.vars["prompt"])]
for token in llm.stream(messages):
yield stream_chat(token.content)
MDX: Define the page and connect the data.
# 🦜🔗 Langchain Chat
<Chat postData="langchain_chat" height={300} />
- Run
morph serveto open the app!
Documentation
Visit https://docs.morph-data.io for more documentation.
Contributing
Thanks for your interest in helping improve Morph ❤️
- Before contributing, please read the CONTRIBUTING.md.
- If you find any issues, please let us know and open an issue.
Lisence
Morph is Apache 2.0 licensed.
Metadata
Release files for morph-data 0.3.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| morph_data-0.3.1.tar.gz | 94.1 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| morph_data-0.3.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 219.0 kB
Release files / morph_data-0.3.1.tar.gz
| Download URL | morph_data-0.3.1.tar.gz |
|---|---|
| Size | 94.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
462276a7e5973807812cc17da4ab2879e1d94e7beb963c6955139360b6641962
|
|
BLAKE2b-256 checksum How to use checksums |
3ce55254717ca341a7b8747ed061bca7aa29a0c50eda38dea9b4ae885c5fffa9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.2 CPython/3.9.4 Darwin/23.3.0
|
Release files / morph_data-0.3.1-py3-none-any.whl
| Download URL | morph_data-0.3.1-py3-none-any.whl |
|---|---|
| Size | 124.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
a0a3ae34366cf167476ef54d0dd3f0f7685b2b42a3823b0188a36a874d5cc790
|
|
BLAKE2b-256 checksum How to use checksums |
6caf63386d1907010acc2b093eecd3cf32c43e74f07b7ecce16656e629fe8da4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.2 CPython/3.9.4 Darwin/23.3.0
|
Security for morph-data 0.3.1
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.