Saravanan666/pypi-org huggingface dataset:
Package: pyllm-code
PyLLM: In-Line  Executable Code Generation Using LLMsPyLLM harnesses the power of Large Language Models (LLMs) to generate and execute code during runtime. Whether you're automating routine tasks, solving complex problems, or just experimenting with AI-generated code, PyLLM provides a seamless and intuitive interface for code generation and execution.FeaturesDynamic Code Generation: Generate functions on-the-fly in one line.Unit Testing: Specify unit tests to ensure the generated code meets your requirements.Caching Mechanism: Avoid re-generating code for repeated requests with an optional caching feature.Customizable: Easily tune your prompt template and sampling parameters.Installationpip install pyllm-codeQuick StartHere's a simple example to get you started with PyLLM. The following code generates a function to swap two numbers:from pyllm import CodeLLM

llm = CodeLLM()
swap_numbers = llm.def_function(
    "Swap two input numbers", unit_tests=[((1, 2), (2, 1))]
)
print(swap_numbers(20, 40))
# Output: (40, 20)UsageTo generate a function using PyLLM, create a CodeLLM instance and use the function method with the desired description and unit tests:from pyllm import CodeLLM

# Initialize the LLM interface
llm = CodeLLM()

# Generate a function
my_function = llm.def_function(
    "Function description here",
    unit_tests=[("input_example", "expected_output")],
    use_cached=True  # Set to False to disable caching
)ContributingContributions are welcomed from the community, whether it's in the form of bug reports, feature requests, or code contributions. Please refer to our CONTRIBUTING.md for guidelines on how to contribute.LicensePyLLM is released under the MIT license. See the LICENSE file for more details.SupportIf you encounter any issues or have questions, please file an issue on our GitHub repository.Enjoy crafting code with AI through PyLLM!
Package: pyllmp
Large Language Model Programming (LLMP)LLMP provides a high-level abstraction for creating, storing, and optimizing generative NLP tasks. It leverages the power of large language models, enabling users to seamlessly integrate them into their software projects without the hassle of manually crafting and optimizing prompts.Key FeaturesJob Creation: Define jobs using input and output object structures.Auto-Optimization: LLMP automatically optimizes prompts to achieve desired outputs.Metrics Collection: Evaluate the performance of prompts in terms of accuracy, efficiency, and cost.Storage Management: Jobs are organized and stored systematically for easy retrieval and management.Documentation and ExamplesFor detailed documentation and examples, please refer to the:Full documentation:project documentation.API Reference:API reference.Quick StartInstallationpipinstallpyllmpCreating a JobfrompydanticimportBaseModelfromtypingimportLiteralfromllmp.services.programimportProgramclassInputObject(BaseModel):book_title:strbook_author:strrelease_year:intclassOutputObject(BaseModel):genre:Literal["fiction","non-fiction","fantasy","sci-fi","romance","thriller","horror","other"]# Initialize a jobprogram=Program("Book to Genre",input_model=InputObject,output_model=OutputObject)Loading a Jobprogram=Program("Book to Genre")Running a JobAfter creating or loading a job, you can easily execute it with input data to get the desired output.input_data={"book_title":"The Lord of the Rings","book_author":"J. R. R. Tolkien","release_year":1954}result=program(input_data=input_data)print(result)Output:{
    "genre": "fantasy"
}Monitoring a JobTo monitor existing jobs, you can use thestreamlitcommand-line tool to run the monitoring application. Navigate to thelibs/llmp-monitordirectory and run the following command:streamlitrunapp.pyHere you can past your local job directory path to monitor, update and optimize jobs located in that directory.
Once you have run the command and entered the path, you can access the monitoring application athttp://localhost:8501.
You should see a screen similar to the following:ArchitectureLLMP follows a component-based architecture with service layers, ensuring modularity and scalability. For detailed insights into the architecture, refer to the project documentation.ContributeLLMP is an open-source project. Contributions, feedback, and suggestions are welcome! Please check out theCONTRIBUTING.mdguide for more details.LicenseThis project is licensed under the MIT License. See theLICENSEfile for details.
Package: pylluvial
pylluvialA python library for creating alluvial diagrams with an arbitrary number of layersInstallationSimply run the followingpip install pylluvialor clone the repositorygit clone git@github.com:dmalzl/pylluvial.gitand runcd pyluvial
pip install .you should then be able to import the package as usualUsageA minimal usage example would be as followsimportpylluvialaspadata=pa.generate_test_data([3,4,3,2])# by default labels are not shownfig,ax=pa.alluvial(x='timepoint',stratum='module',alluvium='nodename',data=data,palette='husl',stratum_gap=2,stratum_width=2)fig.set_figwidth(10)fig.set_figheight(5)fig.tight_layout()# pass show_labels = True to get labelled plotsfig,ax=pa.alluvial(x='timepoint',stratum='module',alluvium='nodename',palette='husl',data=data,stratum_gap=2,stratum_width=2,show_labels=True)fig.set_figwidth(10)fig.set_figheight(5)fig.tight_layout()# use hue to split strata by a given grouping variablefig,ax=pa.alluvial(x='timepoint',stratum='module',alluvium='nodename',hue='signif',palette='tab20',data=data,stratum_gap=2,stratum_width=2,show_labels=True)fig.set_figwidth(10)fig.set_figheight(5)fig.tight_layout()The color assignment for hue elements using string arguments for palette can be quite cumbersome.
However, you can always pass a dictionary with the colors you want to use to palette instead of a stringtab20_colors={'1_s':'#1F77B5','1_ns':'#B0C6E8','2_s':'#F07E21','2_ns':'#F9BA79','3_s':'#2AA137','3_ns':'#9DCB88','4_s':'#D62828','4_ns':'#F29697'}colors={f't{i}':tab20_colorsforiinrange(4)}fig,ax=pa.alluvial(x='timepoint',stratum='module',alluvium='nodename',hue='signif',palette=colors,data=data,stratum_gap=2,stratum_width=2,show_labels=True)
Package: pylm
Pylm is the Python implementation of PALM, a framework to build
clusters of high performance components. It is presented in two
different levels of abstraction. In the high level API you will find
servers and clients that are functionalout of the box. Use the high
level API if you are interested in simple communication patterns like
client-server, master-slave or a streaming pipeline. In the low level
API there are a variety of small components that, once combined,
they can be used to implement almost any kind of
component. It’s what the high level API uses under the hood. Choose
the low level API if you are interested in creating your custom
component and your custom communication pattern.Pylm requires a version of Python equal or higher than 3.4, and it is
more thoroughly tested with Python 3.5.Installingpylmis as easy as:$>pipinstallpylmPYPI package pageDocumentationSource codePylm is released under a dual licensing scheme. The source is released
as-is under the the AGPL version 3 license, a copy of the license is
included with the source. If this license does not suit you,
you can purchase a commercial license fromNFQ SolutionsThis project has been funded by the Spanish Ministry of Economy and
Competitivity under the grant IDI-20150936, cofinanced with FEDER
funds.
Package: py-lmd
py-lmdThe py-lmd library allows to read, modify and write shape files for the Leica LMD6 & LMD7 microscope.
Additionally, functionality for the calibration, generation of final pulses and import of vektor files is included.Installation from pypiIf you would like to install the py-lmd for use in your project, you can directly install it from the python package index.pip install py-lmdInstallation from GithubYou can also install py-lmd directly from Github for development purposes.git clone https://github.com/GeorgWa/py-lmd.git
pip install -e py-lmdRelease a new VersionMake sure the version number on the main branch is up to date.py-lmd/setup.py
py-lmd/docs/conf.pyCreate a new build.python3 -m buildUpload it to PyPi:python3 -m twine upload dist/*
Package: pylmeasure
PyLMeasure: A Python Wrapper for LMeasure.PyLMeasureis a Python wrapper library for thecommand-line interfaceof the neuronal morphology analysis toolL-Measure.InstallationTo install the library, simply type inpip install pylmeasurein your terminal.The above command includes the necessary binaries -- no need to download L-Measure separatelly or install Java.UsageThe basic usage is:from pylmeasure import *

# Specify the L-Measure to compute, full list: http://cng.gmu.edu:8080/Lm/help/index.htm
LMOutput = getOneMeasure('Surface', 'path/to/cell.swc')

print("Surface area:",  LMOutput["TotalSum"])For more examples, seethis Jupyter notebook.IssuesIf you encounter an issue, first make sure it's not due to L-Measure itself -- this library simply wraps the L-Measure executables. If it is, please contact theL-Measure team. If the issue is with this library, please create anissue on Github.ContributingTo contribute, pleaseopen an issuefirst and discuss your plan for contributing. Then fork this repository and commita pull-requestwith your changes.AcknowledgementsThis wrapper library project was initialy started byAjayrama Kumaraswamy. Viewthe original source.
Package: pylmod
PyLmodPyLmod:Python implementation of MIT Learning Modules APIVersion:1.0.2Author:MIT Office of Digital LearningHomepage:http://engineering.odl.mit.eduLicense:BSDPyLmod provides a Python library to access the MIT Learning Modules web
service (described below). PyLmod was created to support
MIT’s use of OpenedX for residential courses, but the library is open
source to enable easier access to that service for Python application
developers at MIT. PyLmod encapsulates the Learning Modules web service
making it more pythonic and easier to incorporate into Python applications.The MIT Learning Modules web service, maintained by MIT Information
Systems and Technologies (IS&T), exposes an API to MIT systems of
record for classes, students, and grades. Its documentation is available
at these links.MIT Learning Modules web service documentation:Gradebook module docMembership module docGetting StartedThe Learning Modules web service requires authentication by x.509
certificates. You must create an application certificate and configure
the Learning Modules web service to recognize it. MIT developers can
use thisIS&T guideto create an application
certificate. TheMITx Knowledge Basealso contains an article ‘MIT Application Certificates” that explains
the steps in greater detail.Once you have your application certificate you must get the Learning
Modules service to recognize it. The app certificate needs to have
an account on the service and then the proper role(s) in the proper
group(s). Send your application certificate tolearningmod-support@mit.eduwith a request for access. Inform them what your application will do and
they will assist in configuring your certificate.
This service, maintained by MIT Information Systems and Technologies
(IS&T) exposes an API to MIT systems of record for classes, students, and
grades. PyLmod was created to support MIT’s
use of OpenedX for residential courses, but the library is open source
to enable easier access for Python application developers at MIT.DevelopmentSee theDevelopment NotesLicensingPyLmod is licensed under the BSD license, version January 9, 2008.  See
LICENSE for the full text of the license.
Package: pylm-registry
Pylm is the Python implementation of PALM, a framework to build
clusters of high performance components. Pylm-registry provides
a set of tools to launch and monitor PALM clusters.Pylm requires a version of Python equal or higher than 3.4, and it is
more thoroughly tested with Python 3.5.Installingpylmis as easy as:$>pipinstallpylm-registryPYPI package pageDocumentationSource codePylm is released under a dual licensing scheme. The source is released
as-is under the the AGPL version 3 license, a copy of the license is
included with the source. If this license does not suit you,
you can purchase a commercial license fromNFQ SolutionsThis project has been funded by the Spanish Ministry of Economy and
Competitivity under the grant IDI-20150936, cofinanced with FEDER
funds.
Package: pylnbits-lngames
pylnbitspython library of methods for accessing lnbits.com API or your own install.Getting Startedgit clone https://github.com/lightningames/pylnbits
cd pylnbits
python -m venv venv
source venv/bin/activate
pip install -r requirements.txt
pip install -e .Check linting and formattingpre-commit run -aBuild for distributionpython3 -m buildRun TestsTBD
TBD
Package: pyln-client
pyln-client: A python client library for lightningdThis package implements the Unix socket based JSON-RPC protocol thatlightningdexposes to the rest of the world. It can be used to call
arbitrary functions on the RPC interface, and serves as a basis for plugins
written in python.Installationpyln-clientis available onpip:pip install pyln-clientAlternatively you can also install the development version to get access to
currently unreleased features by checking out the Core Lightning source code and
installing into your python3 environment:gitclonehttps://github.com/ElementsProject/lightning.gitcdlightning/contrib/pyln-client
poetryinstallThis will add links to the library into your environment so changing the
checked out source code will also result in the environment picking up these
changes. Notice however that unreleased versions may change API without
warning, so test thoroughly with the released version.ExamplesUsing the JSON-RPC client"""Generate invoice on one daemon and pay it on the other"""frompyln.clientimportLightningRpcimportrandom# Create two instances of the LightningRpc object using two different Core Lightning daemons on your computerl1=LightningRpc("/tmp/lightning1/lightning-rpc")l5=LightningRpc("/tmp/lightning5/lightning-rpc")info5=l5.getinfo()print(info5)# Create invoice for test paymentinvoice=l5.invoice(100,"lbl{}".format(random.random()),"testpayment")print(invoice)# Get route to l1route=l1.getroute(info5['id'],100,1)print(route)# Pay invoiceprint(l1.sendpay(route['route'],invoice['payment_hash']))Writing a pluginPlugins are programs thatlightningdcan be configured to execute alongside
the main daemon. They allow advanced interactions with and customizations to
the daemon.#!/usr/bin/env python3frompyln.clientimportPluginplugin=Plugin()@plugin.method("hello")defhello(plugin,name="world"):"""This is the documentation string for the hello-function.It gets reported as the description when registering the functionas a method with `lightningd`.If this returns (a dict), that's the JSON "result" returned.  Ifit raises an exception, that causes a JSON "error" return (raisingpyln.client.RpcException allows finer control over the return)."""greeting=plugin.get_option('greeting')s='{}{}'.format(greeting,name)plugin.log(s)returns@plugin.init()definit(options,configuration,plugin):plugin.log("Plugin helloworld.py initialized")# This can also return {'disabled': <reason>} to self-disable,# but normally it returns None.@plugin.subscribe("connect")defon_connect(plugin,connect,**kwargs):plugin.log("Received connect event for peer{}".format(connect))plugin.add_option('greeting','Hello','The greeting I should use.')plugin.run()
Package: pylnd
pylndPython client for Lightning Network Deamon(LND)with batteries included.Planned support for both REST and gRPC.Only supporting Python 3 since we should not be using Python 2.x anymore.Getting startedDevelopmentMake a virtual environment,python3-mvirtualenv-ppython3.venvsource.venv/bin/activateThen install,python setup.py developTo run tests execute,pytestwith code coverage,pytest --cov=pylndLicenseThis project is licensed under the MIT License - see the LICENSE file for details
Package: pylnk
Python library for reading and writing Windows shortcut files (.lnk)This library can parse .lnk files and extract all relevant information from
them which is especially helpful if you need to do this on a non-ms-windows
machine. Parsing a .lnk file yields a LNK object which can be altered and saved
again. Moreover, .lnk file can be created from scratch be creating a LNK
object, populating it with data and then saving it to a file. As that
process requires some knowledge about the internals of .lnk files, some
convenience functions are provided.Limitation: Windows knows lots of different types of shortcuts which all have
different formats. This library currently only supports shortcuts to files and
folders on the local machine.
Package: pylnk3
PyLnk 3Python library for reading and writing Windows shortcut files (.lnk).Converted to support python 3.This library can parse .lnk files and extract all relevant information from
them. Parsing a .lnk file yields a LNK object which can be altered and saved
again. Moreover, .lnk file can be created from scratch be creating a LNK
object, populating it with data and then saving it to a file. As that
process requires some knowledge about the internals of .lnk files, some
convenience functions are provided.Limitation: Windows knows lots of different types of shortcuts which all have
different formats. This library currently only supports shortcuts to files and
folders on the local machine.CLIMainly tool has two basic commands.Parse existed lnk filepylnk3parse[-h]filename[props[props...]]positionalarguments:filenamelnkfilenametoreadpropspropspathtoreadoptionalarguments:-h,--helpshowthishelpmessageandexitCreate new lnk fileusage:pylnk3create[-h][--arguments[ARGUMENTS]][--description[DESCRIPTION]][--icon[ICON]][--icon-index[ICON_INDEX]][--workdir[WORKDIR]][--mode[{Maximized,Normal,Minimized}]]targetname

positionalarguments:targettargetpathnamelnkfilenametocreate

optionalarguments:-h,--helpshowthishelpmessageandexit--arguments[ARGUMENTS],-a[ARGUMENTS]additionalarguments--description[DESCRIPTION],-d[DESCRIPTION]description--icon[ICON],-i[ICON]iconfilename--icon-index[ICON_INDEX],-ii[ICON_INDEX]iconindex--workdir[WORKDIR],-w[WORKDIR]workingdirectory--mode[{Maximized,Normal,Minimized}],-m[{Maximized,Normal,Minimized}]windowmodeExamplespylnk3pfilename.lnk
pylnk3cc:\prog.exeshortcut.lnk
pylnk3c\\192.168.1.1\share\file.docdoc.lnk
pylnk3createc:\1.txttext.lnk-mMinimized-d"Description"Changes0.4.2changed logic for Lnk.path choose (in case of different paths presents at different structures)read links with root as GUID of KNOWN_FOLDER[FIX] disabled padding for writing LinkInfo.local_base_path0.4.0added support for network linksreworked CLI (added more options for creating links)added entry point for call tool just likepylnk3[FIX] allow build links for non-existed (from this machine) paths[FIX] correct building links on Linux (now expect Windows-like path)[FIX] fixed path priority at parsing with both local & remote presents0.3.0added support links to UWP apps0.2.1released to PyPI0.2.0converted to python 3
Package: pylnlib
pylnlibA python library to monitor LocoNet traffic on a usb/serial bus.Documentation (a work in progress) can be found onhttps://varkenvarken.github.io/pylnlib/installationjust the library:pipinstallpylnlibwith the experimental webserver (this will also pull all dependencies, like fastapi, uvicorn, etc):pipinstallpylnlib[webserver]
Package: pyln-proto
pyln-proto: Lightning Network protocol implementationThis package implements some of the Lightning Network protocol in pure
python. It is intended for protocol testing and some minor tooling only. It is
not deemed secure enough to handle any amount of real funds (you have been
warned!).Installationpyln-protois available onpip:pip install pyln-protoAlternatively you can also install the development version to get access to
currently unreleased features by checking out the Core Lightning source code and
installing into your python3 environment:gitclonehttps://github.com/ElementsProject/lightning.gitcdlightning/contrib/pyln-proto
poetryinstallThis will add links to the library into your environment so changing the
checked out source code will also result in the environment picking up these
changes. Notice however that unreleased versions may change API without
warning, so test thoroughly with the released version.
Package: pyln-testing
pyln-testing: A library to write tests against Core LightningThis library implements a number of utilities that help building tests for
Core Lightning nodes. In particular it provides a number of pytest fixtures that
allow the management of a test network of a given topology and then execute a
test scenarion.pyln-testingis used by Core Lightning for its internal tests, and by the
community plugin directory to exercise the plugins.Installationpyln-testingis available onpip:pipinstallpyln-testingAlternatively you can also install the development version to get access to
currently unreleased features by checking out the Core Lightning source code and
installing into your python3 environment:gitclonehttps://github.com/ElementsProject/lightning.gitcdlightning/contrib/pyln-testing
poetryinstallThis will add links to the library into your environment so changing the
checked out source code will also result in the environment picking up these
changes. Notice however that unreleased versions may change API without
warning, so test thoroughly with the released version.Testing GRPC BindingsThe grpc bindings can be tested by setting theCLN_TEST_GRPC=1environment variable. This will cause the testing framework to use a
grpc client to talk to thecln-grpcplugin, rather than talking
directly to the node's JSON-RPC interface. Since the GRPC related
dependencies are guarded behind a feature flag inpyln-testingyou'll need to install it with thegrpcfeature enabled in order to
be able to run in this mode.Below is a diagram of how the normal JSON-RPC interaction looks like,
followed by one that display the grpc interaction:CLN -- JSON-RPC -- LightningRpc -- pytest
\_____CLN_____/    \_______pytest_______/CLN -- JSON-RPC -- cln-rpc -- rpc2grpc converters -- grpc interface -- python grpc client -- python grpc2json converter -- pytest
\_____CLN_____/    \___________cln-grpc-plugin____________________/    \__________________________pytest________________________/As you can see the grpc mode attempts to emulate the simple JSON-RPC
mode by passing the call through a number of conversions. The last
stepgrpc2jsonis rather incomplete, and will cause quite a few
tests to fail for now, until the conversion is completed and we reach
feature parity between the interaction modes.
Package: pyloading
PyloadingLoading made easy!This can Easily be used anywhere in programs(console based)Pyloading contains a clear screen for all the OS.It also have two console based loading screens - rotating one and a common loading bar.To implement Pyloadingsteps:opencmdand typepip install pyloadingopen a python filetype in the followingimportpyloadingaspylpyl.loadingC()pyl.loading_bar()pyl.cls()and your done!All the functions have parameters (exept cls) which can be used to change the functionallity of themSource code available atgithubPyloading uses:itertoolsosthreadingtimesystqdmtimeChange log1.0.0(27/6/2021)First realease