citecheck 0.3.0

Creator: codyrutscher

Last updated:

Add to Cart

Description:

citecheck 0.3.0

citecheck: like typechecks, but for citations 📖⛓️












Quick example
Consider this example (all authors and quantities are fictitious):

Doe (2021) published a method for estimating Vt as a function of qp and t.
Bloggs (2023) published a method for estimating Rm as a function of Vt and
ρ, with the explicit requirement that Vt be estimated using the method of
Doe (2021) in particular.

The goal for citecheck is that you could implement this as follows:
from citecheck import enforcecite, Cite

@enforcecite
def calc_vt_doe2021(
qt: float,
t: float
) -> Annotated[float, Cite("doe2021")]:
...

@enforcecite
def calc_rm_bloggs2023(
vt: Annotated[float, Cite("doe2021")],
rho: float
) -> Annotated[float, Cite("bloggs2023")]:
...

Now, if we try to pass a value for Vt that was not estimated using the method of Doe
(2021), we would get an error:
calc_rm_bloggs2023(vt=1.0, rho=1.0) # Error
calc_rm_bloggs2023(vt=calc_vt_doe2021(1.0, 1.0), rho=1.0) # OK

citecheck is still in development, but this is the general idea.
When to use citecheck
You should consider using citecheck when you are implementing functions corresponding to
equations or methodologies in multiple papers which refer to one another.
Getting Started with Development
Use Linux, install pyenv, and then run the setup
script:
source .\scripts\dev-setup.sh

License

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Customer Reviews

There are no reviews.