cs-models 0.0.546__py3-none-any.whl → 0.0.548__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.

Potentially problematic release.


This version of cs-models might be problematic. Click here for more details.

@@ -0,0 +1,33 @@
1
+ from datetime import datetime
2
+
3
+ from sqlalchemy import (
4
+ Column,
5
+ Integer,
6
+ Text,
7
+ DateTime,
8
+ ForeignKey,
9
+ Boolean,
10
+ )
11
+
12
+ from ...database import Base
13
+
14
+
15
+ class InterventionNormNoteLinkModel(Base):
16
+ __tablename__ = "intervention_norm_notes_links"
17
+
18
+ id = Column(Integer, primary_key=True)
19
+ intervention_norm_id = Column(
20
+ Integer,
21
+ ForeignKey('intervention_norm.id'),
22
+ nullable=False,
23
+ )
24
+ notes = Column(Text, nullable=True)
25
+ is_external = Column(Boolean, nullable=True)
26
+ is_deleted = Column(Boolean, nullable=True)
27
+ updated_at = Column(
28
+ DateTime,
29
+ nullable=False,
30
+ # https://stackoverflow.com/questions/58776476/why-doesnt-freezegun-work-with-sqlalchemy-default-values
31
+ default=lambda: datetime.utcnow(),
32
+ onupdate=lambda: datetime.utcnow(),
33
+ )
@@ -0,0 +1,16 @@
1
+ from marshmallow import (
2
+ Schema,
3
+ fields,
4
+ validate,
5
+ )
6
+
7
+
8
+ class InterventionNormNoteLinkResourceSchema(Schema):
9
+ not_blank = validate.Length(min=1, error='Field cannot be blank')
10
+
11
+ id = fields.Integer(dump_only=True)
12
+ intervention_norm_id = fields.Integer(required=True)
13
+ notes = fields.String(allow_none=True)
14
+ is_external = fields.Boolean(allow_none=True)
15
+ is_deleted = fields.Boolean(allow_none=True)
16
+ updated_at = fields.DateTime()
File without changes
@@ -0,0 +1,29 @@
1
+ from datetime import datetime
2
+
3
+ from sqlalchemy import (
4
+ Column,
5
+ Integer,
6
+ DateTime,
7
+ String,
8
+ Text,
9
+ )
10
+
11
+ from ...database import Base
12
+
13
+
14
+ class LLMCacheModel(Base):
15
+ __tablename__ = "llm_cache"
16
+
17
+ id = Column(Integer, primary_key=True)
18
+ message = Column(String(191), nullable=False)
19
+ response = Column(Text, nullable=False)
20
+ model_name = Column(String(50), nullable=False)
21
+ model_provider = Column(String(20), nullable=False)
22
+ model_prompt = Column(Text, nullable=False)
23
+ updated_at = Column(
24
+ DateTime,
25
+ nullable=False,
26
+ # https://stackoverflow.com/questions/58776476/why-doesnt-freezegun-work-with-sqlalchemy-default-values
27
+ default=lambda: datetime.utcnow(),
28
+ onupdate=lambda: datetime.utcnow(),
29
+ )
@@ -0,0 +1,17 @@
1
+ from marshmallow import (
2
+ Schema,
3
+ fields,
4
+ validate,
5
+ )
6
+
7
+
8
+ class LLMCacheResourceSchema(Schema):
9
+ not_blank = validate.Length(min=1, error='Field cannot be blank')
10
+
11
+ id = fields.Integer(dump_only=True)
12
+ message = fields.String(required=True)
13
+ response = fields.String(required=True)
14
+ model_name = fields.String(required=True)
15
+ model_provider = fields.String(required=True)
16
+ model_prompt = fields.String(required=True)
17
+ updated_at = fields.DateTime()
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: cs-models
3
- Version: 0.0.546
3
+ Version: 0.0.548
4
4
  Summary: MySQL db models
5
5
  Home-page: https://github.com/ezpz76/cs-models
6
6
  Author: Harsh Verma
@@ -341,6 +341,9 @@ cs_models/resources/InterventionNewswire/schemas.py,sha256=0LhOhA40vgyfmjOYa1Fqy
341
341
  cs_models/resources/InterventionNorm/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
342
342
  cs_models/resources/InterventionNorm/models.py,sha256=2KlKyaECUfytlJbic7iZs3DJm-Mx14mcxd-D6H92G7k,989
343
343
  cs_models/resources/InterventionNorm/schemas.py,sha256=LV96BOCX_ARC0KpsHOt_2AbYYmjiXCF6gAqIVEI3JF0,933
344
+ cs_models/resources/InterventionNormNotesLinks/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
345
+ cs_models/resources/InterventionNormNotesLinks/models.py,sha256=f-cb-19ksZ_78uD_88NdlslaNd8nuNQvtX7snlWN6DU,842
346
+ cs_models/resources/InterventionNormNotesLinks/schemas.py,sha256=kB0k3Do-lI6yQ5B8DNxy8MM2l26OhZ93NcgXeyKhsSc,467
344
347
  cs_models/resources/InterventionPharmAction/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
345
348
  cs_models/resources/InterventionPharmAction/models.py,sha256=wpJraKCerB4oZSjWxMkU97j60d8X3g4fGhJ_8LNR4RA,948
346
349
  cs_models/resources/InterventionPharmAction/schemas.py,sha256=8UvUqC2-44zSasVGodE2DSjmymZp-bi-VKpTVR6BPnU,420
@@ -368,6 +371,9 @@ cs_models/resources/Investor/schemas.py,sha256=VOh1J-mcdu2zxV9YKlrRws-gdBdHjCt4l
368
371
  cs_models/resources/InvestorAlias/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
369
372
  cs_models/resources/InvestorAlias/models.py,sha256=bPFT96IglhqjYIqxPk-MQW2cZOFeF7NvP_H9EkNdVHE,700
370
373
  cs_models/resources/InvestorAlias/schemas.py,sha256=Wn9ACbxGwbNaFoc9Lv86qMJTBwmMChfoWB9ghp2kTQQ,348
374
+ cs_models/resources/LLMCache/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
375
+ cs_models/resources/LLMCache/models.py,sha256=Std5BPOsMFvGArvzIbIs5Mscwg1vtsuaTlTJbDzIC34,776
376
+ cs_models/resources/LLMCache/schemas.py,sha256=7RTxC4ZqNyd3c2r_NqbG-d6QoIaOMS6U4-Bcw7py4pE,483
371
377
  cs_models/resources/LatestPipelineProduct/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
372
378
  cs_models/resources/LatestPipelineProduct/models.py,sha256=UZKXNTaDpAsr13miUx_lHkrwhbTYehpcB0TwLgAz--k,988
373
379
  cs_models/resources/LatestPipelineProduct/schemas.py,sha256=_yTbddbRov58yE8MdiZk4_VBK92EYQU9VXPUMw7bf18,1476
@@ -884,7 +890,7 @@ cs_models/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
884
890
  cs_models/utils/alchemy.py,sha256=fhINGFn41owJ2DLXQKXAAtLqeZ1BRzD_qU0wPK_bsGQ,1598
885
891
  cs_models/utils/utils.py,sha256=bY623DuzycfPQiaOQT2AxfANeWfwr5w76dBuQ813-ns,3664
886
892
  cs_models/utils/profiling/__init__.py,sha256=N-73vb0M92C975fxgXyBCBjCPELl8Oh21ZY_-tzDnns,569
887
- cs_models-0.0.546.dist-info/METADATA,sha256=8u7lI9YpaMl4PyHyAhrtJ3xcxcDktj2Tlla163RoO7E,796
888
- cs_models-0.0.546.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92
889
- cs_models-0.0.546.dist-info/top_level.txt,sha256=M7CA8Nh5t0vRManQ9gHfphhO16uhMqIbfaxr1jPDg18,10
890
- cs_models-0.0.546.dist-info/RECORD,,
893
+ cs_models-0.0.548.dist-info/METADATA,sha256=sR9OWG6gSegCKUg9fO0_IHoMBvA1T26HQ_QNq_LJgt0,796
894
+ cs_models-0.0.548.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92
895
+ cs_models-0.0.548.dist-info/top_level.txt,sha256=M7CA8Nh5t0vRManQ9gHfphhO16uhMqIbfaxr1jPDg18,10
896
+ cs_models-0.0.548.dist-info/RECORD,,