memos 0.1.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
memos/__init__.py ADDED
File without changes
memos/commands.py ADDED
@@ -0,0 +1,19 @@
1
+ import typer
2
+ import httpx
3
+ from memos.server import run_server
4
+
5
+ app = typer.Typer()
6
+
7
+ @app.command()
8
+ def serve():
9
+ run_server()
10
+
11
+ @app.command()
12
+ def ls():
13
+ response = httpx.get("http://localhost:8080/libraries")
14
+ libraries = response.json()
15
+ for library in libraries:
16
+ print(library['name'])
17
+
18
+ if __name__ == "__main__":
19
+ app()
memos/main.py ADDED
@@ -0,0 +1,7 @@
1
+ from fastapi import FastAPI
2
+
3
+ app = FastAPI()
4
+
5
+ @app.get("/libraries")
6
+ async def get_libraries():
7
+ return [{"name": "Library1"}, {"name": "Library2"}]
memos/server.py ADDED
@@ -0,0 +1,4 @@
1
+ import uvicorn
2
+
3
+ def run_server():
4
+ uvicorn.run("memos.main:app", host="0.0.0.0", port=8080, reload=True)
@@ -0,0 +1,15 @@
1
+ Metadata-Version: 2.1
2
+ Name: memos
3
+ Version: 0.1.0
4
+ Home-page: https://github.com/arkohut/memos
5
+ Author: arkohut
6
+ Requires-Python: >=3.10
7
+ Description-Content-Type: text/markdown
8
+ Requires-Dist: fastapi
9
+ Requires-Dist: uvicorn
10
+ Requires-Dist: httpx
11
+ Requires-Dist: typer
12
+
13
+ # Memos
14
+
15
+ A project to index everything to make it like another memory.
@@ -0,0 +1,9 @@
1
+ memos/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
+ memos/commands.py,sha256=zkwPKJyPfWPTwuxw33fRa_FinaXLihIjKHtGMOpmwFo,346
3
+ memos/main.py,sha256=3sd5qmHr3YaAhHNfk_gwJ4iBrkiLxoKXRAnfzyzzF2M,152
4
+ memos/server.py,sha256=MFnt_2jztBuirTz5naLVYkUvaQSpRMrxKM-D0xd1rpQ,108
5
+ memos-0.1.0.dist-info/METADATA,sha256=Oswj-jEtzAQhwzoLZQmH0mi5qYPUYed5Omf-kzxMU0Y,333
6
+ memos-0.1.0.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
7
+ memos-0.1.0.dist-info/entry_points.txt,sha256=1k-MxquiI6XPQL2Jw4LBWlufcR7L5Tktu_Huh28UEWY,45
8
+ memos-0.1.0.dist-info/top_level.txt,sha256=Zja3LUabhfiuQUP8L0kJQu9Ip5RjrOmHRp3dDoVvGd8,6
9
+ memos-0.1.0.dist-info/RECORD,,
@@ -0,0 +1,5 @@
1
+ Wheel-Version: 1.0
2
+ Generator: bdist_wheel (0.43.0)
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
5
+
@@ -0,0 +1,2 @@
1
+ [console_scripts]
2
+ memos = memos.commands:app
@@ -0,0 +1 @@
1
+ memos