divi 0.0.1.dev7__py3-none-any.whl → 0.0.1.dev15__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.
Files changed (59) hide show
  1. divi/__init__.py +11 -4
  2. divi/config/config.py +0 -0
  3. divi/decorators/__init__.py +4 -0
  4. divi/decorators/obs_openai.py +33 -0
  5. divi/decorators/observable.py +137 -0
  6. divi/proto/common/v1/common.proto +49 -0
  7. divi/proto/common/v1/common_pb2.py +43 -0
  8. divi/proto/common/v1/common_pb2.pyi +44 -0
  9. divi/proto/core/health/v1/health_service.proto +17 -0
  10. divi/proto/core/{v1/health_check_response_pb2.py → health/v1/health_service_pb2.py} +11 -7
  11. divi/proto/core/{v1/health_check_response_pb2.pyi → health/v1/health_service_pb2.pyi} +6 -0
  12. divi/proto/core/{v1/core_pb2_grpc.py → health/v1/health_service_pb2_grpc.py} +19 -20
  13. divi/proto/metric/v1/metric.proto +26 -0
  14. divi/proto/metric/v1/metric_pb2.py +40 -0
  15. divi/proto/metric/v1/metric_pb2.pyi +25 -0
  16. divi/proto/trace/v1/trace.proto +47 -0
  17. divi/proto/trace/v1/trace_pb2.py +42 -0
  18. divi/proto/trace/v1/trace_pb2.pyi +40 -0
  19. divi/services/__init__.py +7 -0
  20. divi/services/auth/__init__.py +4 -0
  21. divi/services/auth/auth.py +21 -0
  22. divi/services/auth/init.py +21 -0
  23. divi/services/auth/tokman.py +42 -0
  24. divi/services/core/__init__.py +5 -0
  25. divi/services/core/core.py +35 -0
  26. divi/{core → services/core}/finish.py +4 -4
  27. divi/{core → services/core}/init.py +23 -29
  28. divi/services/datapark/__init__.py +4 -0
  29. divi/services/datapark/datapark.py +63 -0
  30. divi/services/datapark/init.py +5 -0
  31. divi/services/finish.py +9 -0
  32. divi/services/init.py +14 -0
  33. divi/services/service.py +11 -0
  34. divi/session/__init__.py +3 -0
  35. divi/session/session.py +40 -0
  36. divi/session/setup.py +62 -0
  37. divi/session/teardown.py +7 -0
  38. divi/signals/__init__.py +3 -0
  39. divi/signals/trace/__init__.py +3 -0
  40. divi/signals/trace/trace.py +151 -0
  41. divi/utils.py +8 -0
  42. divi-0.0.1.dev15.dist-info/METADATA +17 -0
  43. divi-0.0.1.dev15.dist-info/RECORD +45 -0
  44. divi/bin/core +0 -0
  45. divi/core/__init__.py +0 -5
  46. divi/core/run.py +0 -35
  47. divi/proto/core/v1/core.proto +0 -13
  48. divi/proto/core/v1/core_pb2.py +0 -39
  49. divi/proto/core/v1/core_pb2.pyi +0 -6
  50. divi/proto/core/v1/health_check_request.proto +0 -7
  51. divi/proto/core/v1/health_check_request_pb2.py +0 -37
  52. divi/proto/core/v1/health_check_request_pb2.pyi +0 -11
  53. divi/proto/core/v1/health_check_request_pb2_grpc.py +0 -24
  54. divi/proto/core/v1/health_check_response.proto +0 -10
  55. divi/proto/core/v1/health_check_response_pb2_grpc.py +0 -24
  56. divi-0.0.1.dev7.dist-info/METADATA +0 -33
  57. divi-0.0.1.dev7.dist-info/RECORD +0 -23
  58. {divi-0.0.1.dev7.dist-info → divi-0.0.1.dev15.dist-info}/WHEEL +0 -0
  59. {divi-0.0.1.dev7.dist-info → divi-0.0.1.dev15.dist-info}/licenses/LICENSE +0 -0
@@ -0,0 +1,151 @@
1
+ import os
2
+ import time
3
+ from datetime import UTC, datetime
4
+ from typing import Any, Mapping, Optional
5
+ from uuid import uuid4
6
+
7
+ from pydantic import UUID4
8
+ from typing_extensions import TypedDict
9
+
10
+ from divi.proto.common.v1.common_pb2 import KeyValue
11
+ from divi.proto.trace.v1.trace_pb2 import Span as SpanProto
12
+
13
+
14
+ class NullTime(TypedDict, total=False):
15
+ """Null time"""
16
+
17
+ Time: str
18
+ """Time in iso format"""
19
+ Valid: bool
20
+ """Valid"""
21
+
22
+
23
+ class TraceSignal(TypedDict, total=False):
24
+ """Trace request"""
25
+
26
+ id: str
27
+ """Trace ID UUID4"""
28
+ start_time: str
29
+ """Start time in iso format"""
30
+ end_time: NullTime
31
+ """End time in iso format"""
32
+
33
+
34
+ class Trace:
35
+ def __init__(self, session_id: UUID4):
36
+ self.trace_id: UUID4 = uuid4()
37
+ self.start_time: str | None = None
38
+ self.end_time: str | None = None
39
+ self.session_id: UUID4 = session_id
40
+
41
+ @property
42
+ def signal(self) -> TraceSignal:
43
+ if self.start_time is None:
44
+ raise ValueError("Trace must be started.")
45
+ signal = TraceSignal(
46
+ id=str(self.trace_id),
47
+ start_time=self.start_time,
48
+ )
49
+ if self.end_time is not None:
50
+ signal["end_time"] = NullTime(
51
+ Time=self.end_time,
52
+ Valid=True,
53
+ )
54
+ return signal
55
+
56
+ @staticmethod
57
+ def unix_nano_to_iso(unix_nano: int) -> str:
58
+ return datetime.utcfromtimestamp(unix_nano / 1e9).isoformat()
59
+
60
+ def start(self):
61
+ """Start the trace by recording the current time in nanoseconds."""
62
+ self.start_time = datetime.now(UTC).isoformat()
63
+
64
+ def end(self):
65
+ """End the trace by recording the end time in nanoseconds."""
66
+ if self.start_time is None:
67
+ raise ValueError("Span must be started before ending.")
68
+ self.end_time = datetime.now(UTC).isoformat()
69
+
70
+
71
+ class Span:
72
+ KIND_MAP = {
73
+ "function": SpanProto.SpanKind.SPAN_KIND_FUNCTION,
74
+ "llm": SpanProto.SpanKind.SPAN_KIND_LLM,
75
+ }
76
+
77
+ def __init__(
78
+ self,
79
+ kind: str = "function",
80
+ name: Optional[str] = None,
81
+ metadata: Optional[Mapping[str, Any]] = None,
82
+ ):
83
+ # span_id is a FixedString(8)
84
+ self.span_id: bytes = self._generate_span_id()
85
+ self.name = name
86
+ self.kind = kind
87
+ self.metadata = metadata
88
+ self.start_time_unix_nano: int | None = None
89
+ self.end_time_unix_nano: int | None = None
90
+
91
+ self.trace_id: UUID4 | None = None
92
+ self.parent_span_id: bytes | None = None
93
+
94
+ @property
95
+ def signal(self) -> SpanProto:
96
+ signal: SpanProto = SpanProto(
97
+ name=self.name,
98
+ span_id=self.span_id,
99
+ kind=self._get_kind(self.kind),
100
+ start_time_unix_nano=self.start_time_unix_nano,
101
+ end_time_unix_nano=self.end_time_unix_nano,
102
+ trace_id=self.trace_id.bytes if self.trace_id else None,
103
+ parent_span_id=self.parent_span_id,
104
+ )
105
+ print(self.kind)
106
+ signal.metadata.extend(
107
+ KeyValue(key=k, value=v)
108
+ for k, v in (self.metadata or dict()).items()
109
+ )
110
+ return signal
111
+
112
+ @classmethod
113
+ def _get_kind(cls, kind: str) -> SpanProto.SpanKind:
114
+ if (k := cls.KIND_MAP.get(kind)) is None:
115
+ raise ValueError(
116
+ f"Unknown kind: {kind}. Now allowed: {cls.KIND_MAP.keys()}"
117
+ )
118
+ return k
119
+
120
+ @classmethod
121
+ def _generate_span_id(cls) -> bytes:
122
+ return os.urandom(8)
123
+
124
+ def start(self):
125
+ """Start the span by recording the current time in nanoseconds."""
126
+ self.start_time_unix_nano = time.time_ns()
127
+
128
+ def end(self):
129
+ """End the span by recording the end time in nanoseconds."""
130
+ if self.start_time_unix_nano is None:
131
+ raise ValueError("Span must be started before ending.")
132
+ self.end_time_unix_nano = time.time_ns()
133
+
134
+ def _as_root(self, trace_id: UUID4):
135
+ """Set the span as a root span."""
136
+ self.trace_id = trace_id
137
+ print("as root")
138
+ print(f"name: {self.name}")
139
+ print(f"trace_id: {self.trace_id}")
140
+ print(f"span_id: {self.span_id}")
141
+
142
+ def _add_parent(self, trace_id: UUID4, parent_id: bytes):
143
+ """Set the parent span ID."""
144
+ self.trace_id = trace_id
145
+ self.parent_span_id = parent_id
146
+
147
+ print("add parent")
148
+ print(f"name: {self.name}")
149
+ print(f"trace_id: {trace_id}")
150
+ print(f"span_id: {self.span_id}")
151
+ print(f"parent_span_id: {parent_id}")
divi/utils.py CHANGED
@@ -1,4 +1,6 @@
1
+ import inspect
1
2
  import pathlib
3
+ from typing import Callable
2
4
 
3
5
 
4
6
  def get_server_path() -> str:
@@ -10,5 +12,11 @@ def get_server_path() -> str:
10
12
  return str(path)
11
13
 
12
14
 
15
+ def is_async(func: Callable) -> bool:
16
+ """Inspect function or wrapped function to see if it is async."""
17
+ unwrapped_func = inspect.unwrap(func)
18
+ return inspect.iscoroutinefunction(unwrapped_func)
19
+
20
+
13
21
  if __name__ == "__main__":
14
22
  print(get_server_path())
@@ -0,0 +1,17 @@
1
+ Metadata-Version: 2.4
2
+ Name: divi
3
+ Version: 0.0.1.dev15
4
+ Summary: The Agent Platform for Observability & Evaluation
5
+ License-File: LICENSE
6
+ Requires-Python: >=3.11
7
+ Requires-Dist: grpcio>=1.71.0
8
+ Requires-Dist: protobuf<6.0.dev0,>=5.26.1
9
+ Requires-Dist: pyjwt>=2.10.1
10
+ Requires-Dist: requests>=2.32.3
11
+ Description-Content-Type: text/markdown
12
+
13
+ # Divine Agent
14
+
15
+ Agent Platform for Observability • Evaluation • Playground
16
+
17
+ > The project is still in the development stage. 😇
@@ -0,0 +1,45 @@
1
+ divi/__init__.py,sha256=RmQ9wc0IZRqR9DN6hACn0YMUrhHC_AJ9gXsKrgvkcWs,396
2
+ divi/utils.py,sha256=3iVDogCjqQg0jEjhUKEuQ6vHPFp9w7kXNjSVwXt8KmI,574
3
+ divi/config/config.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
4
+ divi/decorators/__init__.py,sha256=HkyWdC1ctTsVFucCWCkj57JB4NmwONus1d2S2dUbvs4,110
5
+ divi/decorators/obs_openai.py,sha256=4LtQPRgJPPyTOw1318Fi04WYqjIwGX8EP0YiWrTW0dk,1003
6
+ divi/decorators/observable.py,sha256=N_MCX_HbMGpD7v_dxnK6ewhgONGxH4XBO-i-6ybGpkc,4038
7
+ divi/proto/common/v1/common.proto,sha256=Rx8wr0_tOtQ1NseTMnsav4ApD1MDALzQDBA2IvLRTU0,1775
8
+ divi/proto/common/v1/common_pb2.py,sha256=br61OHQVAi6SI3baFcb5xJv2Xd-AZ04A19xeSjLNMXo,2442
9
+ divi/proto/common/v1/common_pb2.pyi,sha256=LmTpFFLxHg2a_qPIdNXXwGEMkbiDcTJdarR9eC-6Fq8,2133
10
+ divi/proto/core/health/v1/health_service.proto,sha256=y39MNiwYiSqxb_JPQI7AmPfNNtP6pbX-WKTseMkjWUM,369
11
+ divi/proto/core/health/v1/health_service_pb2.py,sha256=PKAxy_z7lU1HrwDNIa7AFHha9i8gICCVrcEhpOM79E0,1999
12
+ divi/proto/core/health/v1/health_service_pb2.pyi,sha256=VbYHHTcp3epUVg0lTSxo3xpG52ZGhA7KKMRL5LR5e1c,691
13
+ divi/proto/core/health/v1/health_service_pb2_grpc.py,sha256=6owvQ41KPqSOQ8WjXDjYsunoDVydJfP93vZ4uVSG59s,3953
14
+ divi/proto/metric/v1/metric.proto,sha256=YHRMLUW-MtakHuibR3PJ0s2w5KgV12kc4737iHw0DTk,585
15
+ divi/proto/metric/v1/metric_pb2.py,sha256=uvBhyy8QpaES3Jl82yVfsGazW5654XpRnsdGlpVgIRE,1974
16
+ divi/proto/metric/v1/metric_pb2.pyi,sha256=S7ipsojkD7QZAYefDE4b3PO99Yzc6mOdtSLxH3-b67A,1304
17
+ divi/proto/trace/v1/trace.proto,sha256=mh1nzEgufzRTJx3p8NNute-ozEwEYwClWJTdWUGGVA8,1284
18
+ divi/proto/trace/v1/trace_pb2.py,sha256=CuTkSSvhxCa1bk3Ku7tgLqRSovp_Gi52CZ0zLcLP2Ew,2327
19
+ divi/proto/trace/v1/trace_pb2.pyi,sha256=rPo2Oa3NWrINE_dyOVU9HUYHo5LY82Bm5TMenj5dnK8,2136
20
+ divi/services/__init__.py,sha256=TcVJ_gKxyPIcwhT9GgttqHeyk0icW44uE285KmUiyh4,185
21
+ divi/services/finish.py,sha256=XKPKGJ5cWd5H95G_VpIOlOZOLrcf9StoTs7ayRic2jY,173
22
+ divi/services/init.py,sha256=JVzRQ1m1DTHXFVGUMYnsv-vRvzCO8XFdR6MjIwOL_NY,433
23
+ divi/services/service.py,sha256=1c7JQ49BSdBipGLfVIxTHaNxTuyvVAgrvxV7lyYv_68,285
24
+ divi/services/auth/__init__.py,sha256=PIQ9rQ0jcRqcy03a3BOY7wbzwluIRG_4kI_H4J4mRFk,74
25
+ divi/services/auth/auth.py,sha256=dTpFnNhxbEjzOkBLPQvRblFSO5tedJsdObWTXt84MaE,631
26
+ divi/services/auth/init.py,sha256=UXsOweatrWnuFO9ivSjEsJnHrK9YtStKYX2Nup64KEU,477
27
+ divi/services/auth/tokman.py,sha256=V03wcV6TEy1k9o55teDVB9JZ3Ve2cJdwzWstQhWx4BQ,1070
28
+ divi/services/core/__init__.py,sha256=FWl4ShX0AEnOyL24NEc9mNIVoQOeYO4q0qYX27L_Yyw,111
29
+ divi/services/core/core.py,sha256=PRwPtLgrgmCrejUfKf7HJNrAhGS0paFNZ7JwDToEUAk,1264
30
+ divi/services/core/finish.py,sha256=dIGQpVXcJY4-tKe7A1_VV3yoSHNCDPfOlUltvzvk6VI,231
31
+ divi/services/core/init.py,sha256=e7-fgpOPglBXyEoPkgOAnpJk2ApdFbo7LPupxOb8N-w,1966
32
+ divi/services/datapark/__init__.py,sha256=GbV1mwHE07yutgOlCIYHykSEL5KJ-ApgLutGMzu2eUE,86
33
+ divi/services/datapark/datapark.py,sha256=J96C-K9RCaLT7oWXnMQOM1g7btfIlU7BMWReF3ePOlc,2055
34
+ divi/services/datapark/init.py,sha256=C32f9t3eLsxcYNqEyheh6nW455G2oR0YhhdqBcbN3ec,92
35
+ divi/session/__init__.py,sha256=6lYemv21VQCIHx-xIdi7BxXcPNxVdvE60--8ArReUew,82
36
+ divi/session/session.py,sha256=ID7bQ4CuRPUcZ9S-DSjndiduslYFJukRLuCtChYm3wk,838
37
+ divi/session/setup.py,sha256=jlc3ICR5hRDdrcxoSxi66FYS2TYxqrIJOMgI4i1tEJs,1972
38
+ divi/session/teardown.py,sha256=YiBz_3yCiljMFEofZ60VmRL5sb8WA5GT7EYF8nFznZ4,133
39
+ divi/signals/__init__.py,sha256=K1PaTAMwyBDsK6jJUg4QWy0xVJ_5MA6dlWiUyJeiSQA,44
40
+ divi/signals/trace/__init__.py,sha256=K1PaTAMwyBDsK6jJUg4QWy0xVJ_5MA6dlWiUyJeiSQA,44
41
+ divi/signals/trace/trace.py,sha256=y8Xio8Tp_e1tO8l_DAkUuzMrmENNKfIdklF0iWrjGYk,4547
42
+ divi-0.0.1.dev15.dist-info/METADATA,sha256=pV_UinVgV7tlDH6lgD1eYH-k_enKQGKe_FTDhenmjWM,467
43
+ divi-0.0.1.dev15.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
44
+ divi-0.0.1.dev15.dist-info/licenses/LICENSE,sha256=5OJuZ4wMMEV0DgF0tofhAlS_KLkaUsZwwwDS2U_GwQ0,1063
45
+ divi-0.0.1.dev15.dist-info/RECORD,,
divi/bin/core DELETED
Binary file
divi/core/__init__.py DELETED
@@ -1,5 +0,0 @@
1
- from .init import init
2
- from .finish import finish
3
- from .run import Run
4
-
5
- __all__ = ["init", "finish", "Run"]
divi/core/run.py DELETED
@@ -1,35 +0,0 @@
1
- import grpc
2
-
3
- from subprocess import Popen
4
- from typing import List, Optional, Callable
5
-
6
- import divi
7
-
8
- from divi.proto.core.v1.core_pb2_grpc import CoreStub
9
- from divi.proto.core.v1.health_check_request_pb2 import HealthCheckRequest
10
- from divi.proto.core.v1.health_check_response_pb2 import HealthCheckResponse
11
-
12
-
13
- class Run:
14
- """Core Runtime"""
15
-
16
- def __init__(self, host, port) -> None:
17
- self.host: str = host if host else "localhost"
18
- self.port: int = port if port else 50051
19
- self.process: Optional[Popen] = None
20
- self.hooks: List[Callable[[], None]] = []
21
-
22
- @property
23
- def target(self) -> str:
24
- """Return the target string."""
25
- return f"{self.host}:{self.port}"
26
-
27
- def check_health(self) -> bool:
28
- """Check the health of the service."""
29
- with grpc.insecure_channel(self.target) as channel:
30
- stub = CoreStub(channel)
31
- response: HealthCheckResponse = stub.Check(
32
- HealthCheckRequest(version=divi.__version__)
33
- )
34
- print(f"Health check: {response.message}")
35
- return response.status
@@ -1,13 +0,0 @@
1
- syntax = "proto3";
2
-
3
- package core.v1;
4
-
5
- import "divi/proto/core/v1/health_check_request.proto";
6
- import "divi/proto/core/v1/health_check_response.proto";
7
-
8
- option go_package = "github.com/KaikaikaiFang/divine-agent/core/proto";
9
-
10
- // Health is a service that implements health check.
11
- service Core {
12
- rpc Check(HealthCheckRequest) returns (HealthCheckResponse) {}
13
- }
@@ -1,39 +0,0 @@
1
- # -*- coding: utf-8 -*-
2
- # Generated by the protocol buffer compiler. DO NOT EDIT!
3
- # NO CHECKED-IN PROTOBUF GENCODE
4
- # source: divi/proto/core/v1/core.proto
5
- # Protobuf Python Version: 5.29.0
6
- """Generated protocol buffer code."""
7
- from google.protobuf import descriptor as _descriptor
8
- from google.protobuf import descriptor_pool as _descriptor_pool
9
- from google.protobuf import runtime_version as _runtime_version
10
- from google.protobuf import symbol_database as _symbol_database
11
- from google.protobuf.internal import builder as _builder
12
- _runtime_version.ValidateProtobufRuntimeVersion(
13
- _runtime_version.Domain.PUBLIC,
14
- 5,
15
- 29,
16
- 0,
17
- '',
18
- 'divi/proto/core/v1/core.proto'
19
- )
20
- # @@protoc_insertion_point(imports)
21
-
22
- _sym_db = _symbol_database.Default()
23
-
24
-
25
- from divi.proto.core.v1 import health_check_request_pb2 as divi_dot_proto_dot_core_dot_v1_dot_health__check__request__pb2
26
- from divi.proto.core.v1 import health_check_response_pb2 as divi_dot_proto_dot_core_dot_v1_dot_health__check__response__pb2
27
-
28
-
29
- DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1d\x64ivi/proto/core/v1/core.proto\x12\x07\x63ore.v1\x1a-divi/proto/core/v1/health_check_request.proto\x1a.divi/proto/core/v1/health_check_response.proto2L\n\x04\x43ore\x12\x44\n\x05\x43heck\x12\x1b.core.v1.HealthCheckRequest\x1a\x1c.core.v1.HealthCheckResponse\"\x00\x42\x32Z0github.com/KaikaikaiFang/divine-agent/core/protob\x06proto3')
30
-
31
- _globals = globals()
32
- _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
33
- _builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'divi.proto.core.v1.core_pb2', _globals)
34
- if not _descriptor._USE_C_DESCRIPTORS:
35
- _globals['DESCRIPTOR']._loaded_options = None
36
- _globals['DESCRIPTOR']._serialized_options = b'Z0github.com/KaikaikaiFang/divine-agent/core/proto'
37
- _globals['_CORE']._serialized_start=137
38
- _globals['_CORE']._serialized_end=213
39
- # @@protoc_insertion_point(module_scope)
@@ -1,6 +0,0 @@
1
- from divi.proto.core.v1 import health_check_request_pb2 as _health_check_request_pb2
2
- from divi.proto.core.v1 import health_check_response_pb2 as _health_check_response_pb2
3
- from google.protobuf import descriptor as _descriptor
4
- from typing import ClassVar as _ClassVar
5
-
6
- DESCRIPTOR: _descriptor.FileDescriptor
@@ -1,7 +0,0 @@
1
- syntax = "proto3";
2
-
3
- package core.v1;
4
-
5
- option go_package = "github.com/KaikaikaiFang/divine-agent/core/proto";
6
-
7
- message HealthCheckRequest { string version = 1; }
@@ -1,37 +0,0 @@
1
- # -*- coding: utf-8 -*-
2
- # Generated by the protocol buffer compiler. DO NOT EDIT!
3
- # NO CHECKED-IN PROTOBUF GENCODE
4
- # source: divi/proto/core/v1/health_check_request.proto
5
- # Protobuf Python Version: 5.29.0
6
- """Generated protocol buffer code."""
7
- from google.protobuf import descriptor as _descriptor
8
- from google.protobuf import descriptor_pool as _descriptor_pool
9
- from google.protobuf import runtime_version as _runtime_version
10
- from google.protobuf import symbol_database as _symbol_database
11
- from google.protobuf.internal import builder as _builder
12
- _runtime_version.ValidateProtobufRuntimeVersion(
13
- _runtime_version.Domain.PUBLIC,
14
- 5,
15
- 29,
16
- 0,
17
- '',
18
- 'divi/proto/core/v1/health_check_request.proto'
19
- )
20
- # @@protoc_insertion_point(imports)
21
-
22
- _sym_db = _symbol_database.Default()
23
-
24
-
25
-
26
-
27
- DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n-divi/proto/core/v1/health_check_request.proto\x12\x07\x63ore.v1\"%\n\x12HealthCheckRequest\x12\x0f\n\x07version\x18\x01 \x01(\tB2Z0github.com/KaikaikaiFang/divine-agent/core/protob\x06proto3')
28
-
29
- _globals = globals()
30
- _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
31
- _builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'divi.proto.core.v1.health_check_request_pb2', _globals)
32
- if not _descriptor._USE_C_DESCRIPTORS:
33
- _globals['DESCRIPTOR']._loaded_options = None
34
- _globals['DESCRIPTOR']._serialized_options = b'Z0github.com/KaikaikaiFang/divine-agent/core/proto'
35
- _globals['_HEALTHCHECKREQUEST']._serialized_start=58
36
- _globals['_HEALTHCHECKREQUEST']._serialized_end=95
37
- # @@protoc_insertion_point(module_scope)
@@ -1,11 +0,0 @@
1
- from google.protobuf import descriptor as _descriptor
2
- from google.protobuf import message as _message
3
- from typing import ClassVar as _ClassVar, Optional as _Optional
4
-
5
- DESCRIPTOR: _descriptor.FileDescriptor
6
-
7
- class HealthCheckRequest(_message.Message):
8
- __slots__ = ("version",)
9
- VERSION_FIELD_NUMBER: _ClassVar[int]
10
- version: str
11
- def __init__(self, version: _Optional[str] = ...) -> None: ...
@@ -1,24 +0,0 @@
1
- # Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
2
- """Client and server classes corresponding to protobuf-defined services."""
3
- import grpc
4
- import warnings
5
-
6
-
7
- GRPC_GENERATED_VERSION = '1.69.0'
8
- GRPC_VERSION = grpc.__version__
9
- _version_not_supported = False
10
-
11
- try:
12
- from grpc._utilities import first_version_is_lower
13
- _version_not_supported = first_version_is_lower(GRPC_VERSION, GRPC_GENERATED_VERSION)
14
- except ImportError:
15
- _version_not_supported = True
16
-
17
- if _version_not_supported:
18
- raise RuntimeError(
19
- f'The grpc package installed is at version {GRPC_VERSION},'
20
- + f' but the generated code in divi/proto/core/v1/health_check_request_pb2_grpc.py depends on'
21
- + f' grpcio>={GRPC_GENERATED_VERSION}.'
22
- + f' Please upgrade your grpc module to grpcio>={GRPC_GENERATED_VERSION}'
23
- + f' or downgrade your generated code using grpcio-tools<={GRPC_VERSION}.'
24
- )
@@ -1,10 +0,0 @@
1
- syntax = "proto3";
2
-
3
- package core.v1;
4
-
5
- option go_package = "github.com/KaikaikaiFang/divine-agent/core/proto";
6
-
7
- message HealthCheckResponse {
8
- bool status = 1;
9
- string message = 2;
10
- }
@@ -1,24 +0,0 @@
1
- # Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
2
- """Client and server classes corresponding to protobuf-defined services."""
3
- import grpc
4
- import warnings
5
-
6
-
7
- GRPC_GENERATED_VERSION = '1.69.0'
8
- GRPC_VERSION = grpc.__version__
9
- _version_not_supported = False
10
-
11
- try:
12
- from grpc._utilities import first_version_is_lower
13
- _version_not_supported = first_version_is_lower(GRPC_VERSION, GRPC_GENERATED_VERSION)
14
- except ImportError:
15
- _version_not_supported = True
16
-
17
- if _version_not_supported:
18
- raise RuntimeError(
19
- f'The grpc package installed is at version {GRPC_VERSION},'
20
- + f' but the generated code in divi/proto/core/v1/health_check_response_pb2_grpc.py depends on'
21
- + f' grpcio>={GRPC_GENERATED_VERSION}.'
22
- + f' Please upgrade your grpc module to grpcio>={GRPC_GENERATED_VERSION}'
23
- + f' or downgrade your generated code using grpcio-tools<={GRPC_VERSION}.'
24
- )
@@ -1,33 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: divi
3
- Version: 0.0.1.dev7
4
- Summary: The Agent Platform for Observability & Evaluation
5
- License-File: LICENSE
6
- Requires-Python: >=3.11
7
- Requires-Dist: grpcio>=1.69.0
8
- Requires-Dist: protobuf>=5.29.3
9
- Description-Content-Type: text/markdown
10
-
11
- # divine-agent
12
-
13
- Agent Platform for Observability • Evaluation • Playground
14
-
15
- ## Structure
16
-
17
- > Divine Agent is a monorepo project. The project is structured as follows:
18
-
19
- ```plaintext
20
- .
21
- ├── apps
22
- ├── core
23
- ├── docs
24
- ├── packages
25
- ├── scripts
26
- └── sdk
27
- ```
28
-
29
- ## Thanks
30
-
31
- 1. [uv](https://github.com/astral-sh/uv): An extremely fast Python package and project manager, written in Rust.
32
- 2. [hatch](https://github.com/pypa/hatch): Hatch is a modern, extensible Python project manager.
33
- 3. [github cli](https://cli.github.com/manual): GitHub CLI, or gh, is a command-line interface to GitHub for use in your terminal or your scripts.
@@ -1,23 +0,0 @@
1
- divi/__init__.py,sha256=YTwo-qSDfRDLVQFWhqXKC7czbDIu6lavlmlQjhl-NdU,196
2
- divi/utils.py,sha256=HcGlohwmowcQ-isVo0UtrsOsFbJEhX_earaSv4ggIR4,324
3
- divi/bin/core,sha256=unkwyErTAuP767bu6IYg2kc4i855JjUVBIXGLifajoU,14093980
4
- divi/core/__init__.py,sha256=iAUb96xD4lwqipLItCc87_SVHsorydWj1dh3YTWQiig,108
5
- divi/core/finish.py,sha256=ViF6DndmXMq-MAApN-DgGs3r5bbFQsSWbfeDT_rvsDg,225
6
- divi/core/init.py,sha256=GlfyuT78J65juyket4On_Ot2ZE6Oybtu2tmIoFm9IEo,2048
7
- divi/core/run.py,sha256=bgbtAw9LoIAAhx2Qkxd0AN9CsMZZR68BK1VKiKwk2GM,1106
8
- divi/proto/core/v1/core.proto,sha256=vcuht22OEKbZ0fpLz7JTX4qd7pa5br1pjqU_v57uIQQ,360
9
- divi/proto/core/v1/core_pb2.py,sha256=fG_f3LN_2shsx17-H_BmBM3644sHdR4Za-sVIMkZ5Sg,1899
10
- divi/proto/core/v1/core_pb2.pyi,sha256=JI0HJe_LpOXNjIzR7rdHBhln3VUGTJAfyjUn67EPwXY,307
11
- divi/proto/core/v1/core_pb2_grpc.py,sha256=Sla4N0SjtZPtOVDmF9G2M38dSMyomjpgdlwM7b-7CmQ,3869
12
- divi/proto/core/v1/health_check_request.proto,sha256=SWn6NmtivAkcPLj7Dt7HeSHwdZpWqWFdC7ghsVJMcEQ,162
13
- divi/proto/core/v1/health_check_request_pb2.py,sha256=ZOcFrzDBglDz6K1hWfGKr_PEfNp-yEOdwWxBo_qtgrc,1580
14
- divi/proto/core/v1/health_check_request_pb2.pyi,sha256=MJGIn1BwvGApZAZH0HFaUSTIaO7gqwoxLMZEM7INqEk,405
15
- divi/proto/core/v1/health_check_request_pb2_grpc.py,sha256=E7ah12abIGk-pFFzqAIwgjpekfQajrTlW8A9qYSG7J4,920
16
- divi/proto/core/v1/health_check_response.proto,sha256=BWpN374NCJTIfnDoCgWIPIiokipdHPx8yOsUgu8a2sA,184
17
- divi/proto/core/v1/health_check_response_pb2.py,sha256=BoC2HLpfotx4ac2t_9iFwDXg3yiNjUlTgP0fhGA4uDk,1626
18
- divi/proto/core/v1/health_check_response_pb2.pyi,sha256=pcxpVQ5VkOpyfFoh4am1-4xffRuW69ON-PzqVdOz4EA,492
19
- divi/proto/core/v1/health_check_response_pb2_grpc.py,sha256=Y5BEKSJD5-mMEBwa3ugq-0MnNzyCIKXNX06gzr6MA2o,921
20
- divi-0.0.1.dev7.dist-info/METADATA,sha256=XFIHLFRxL6PfSwMYkE7msKQ-OZb42VFvL60U_1ETdjM,916
21
- divi-0.0.1.dev7.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
22
- divi-0.0.1.dev7.dist-info/licenses/LICENSE,sha256=5OJuZ4wMMEV0DgF0tofhAlS_KLkaUsZwwwDS2U_GwQ0,1063
23
- divi-0.0.1.dev7.dist-info/RECORD,,