From nobody Wed Feb 21 15:17:04 2024 X-Original-To: dev-commits-ports-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Tg0Hj0WHpz59dPK; Wed, 21 Feb 2024 15:17:05 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Tg0Hh5bjFz4t7n; Wed, 21 Feb 2024 15:17:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1708528624; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mqbsgpG5IB3VdOG227q8DJTgn/+mpRyM+sxesEc+sEM=; b=CSYKbGgp258ld21iBHGe3U9h1LkXkRsfWltwvMlMTv0sViHtKXBWfQ29yQDJlKh+P2S90K TMcNAjpnxe5dGHrstUs6IC6q7q2pWzB93SgbyHVG/QZKdEOVn7sWvT+dgJH5dl/wshK94l cCYRHqWLCYRJfLaUbNjPPE+g0yZr/0Zb7mpmMmHZNzFChE/0UaLBB93lSY7kpGS9iDtYO1 YqIzb3s0p7dZ58bLuGf5P5LGXysVUsU2QlqbErEAEG6uiUkwKMaNHecCQz5GSjgF9Nnbtl BOtTGBwN+gS/UFWOHEaxJ0s+XSAf62RRM7NyYNrw3Tmh7GyoGX4dyAlH31u+Lw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1708528624; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=mqbsgpG5IB3VdOG227q8DJTgn/+mpRyM+sxesEc+sEM=; b=vkfJstOgjvU0ZSx7g6CRbRg13Ss3A7Bz5BvMAr49KbQFb9xZrP99dxhmMzSQy3Sy4doGJc ShFCVp4RNzZoePb0nbqZduYQJvjEe3+tMVlRKNdHruYyTUYx/AVYemqPrWN9sVTKfANhVE QV/TowFFX9uQPs+Jm3pR1MAfv8vPL3U3nHdB8XXsmI34mMAQUnWH12QU3YcvKx/7HL/94W 1w0fXtfHa5Xyi4cQZ/KOlyq9kMcqLRm8JydaupYaTTDY1cPfiN2iDnPCpCqkUZj9YrqqZU j/FtbayO+j6f2H/Dp8Ofcrt/dRErmMt+akpo4ILsWs70rXAsvCSf4eRmMttv5Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1708528624; a=rsa-sha256; cv=none; b=dcyhBzl4uOO7KkZ34NG/+h0Qoi12Y92j5Vcv/AyUfsjAJO1cmI7sHjM48VyBKtgbPQSUcw 1oaNORnNM6Ce7ZbshhAoqSzcF6ZGHkrnvQDNw9+RZiwOY+izQptUE7t2IMNMZAbsjSHtUm PSym0oVL7Pa2qH2Rb9XW2i/tmor0hbT2IzzMQxW3hMK3CZF99jPEj03C1Rkaarab7ZTkfO RmkCyfveLCEbjFqfKuGS3y5BRZMw2hVC4prI/QW/gi7Cjm4yvGU6wylxyaOUek76JmjokI aJOKDU9fdCs0V90kipGRBuhZ86vs57jYjAWzDgEIe3hd6mm7chHIJR8RITvVQg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Tg0Hh4V3Bz16kL; Wed, 21 Feb 2024 15:17:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 41LFH4nZ011805; Wed, 21 Feb 2024 15:17:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 41LFH4MW011802; Wed, 21 Feb 2024 15:17:04 GMT (envelope-from git) Date: Wed, 21 Feb 2024 15:17:04 GMT Message-Id: <202402211517.41LFH4MW011802@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Po-Chuan Hsieh Subject: git: 4960f5d5663d - main - devel/py-confection: Add py-confection 0.1.4 List-Id: Commit messages for all branches of the ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-all@freebsd.org X-BeenThere: dev-commits-ports-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: sunpoet X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 4960f5d5663d7a769be76afcc2bb1607d9dd82a0 Auto-Submitted: auto-generated The branch main has been updated by sunpoet: URL: https://cgit.FreeBSD.org/ports/commit/?id=4960f5d5663d7a769be76afcc2bb1607d9dd82a0 commit 4960f5d5663d7a769be76afcc2bb1607d9dd82a0 Author: Po-Chuan Hsieh AuthorDate: 2024-02-21 14:12:46 +0000 Commit: Po-Chuan Hsieh CommitDate: 2024-02-21 15:06:04 +0000 devel/py-confection: Add py-confection 0.1.4 confection is a lightweight library that offers a configuration system letting you conveniently describe arbitrary trees of objects. Configuration is a huge challenge for machine-learning code because you may want to expose almost any detail of any function as a hyperparameter. The setting you want to expose might be arbitrarily far down in your call stack, so it might need to pass all the way through the CLI or REST API, through any number of intermediate functions, affecting the interface of everything along the way. And then once those settings are added, they become hard to remove later. Default values also become hard to change without breaking backwards compatibility. To solve this problem, confection offers a config system that lets you easily describe arbitrary trees of objects. The objects can be created via function calls you register using a simple decorator syntax. You can even version the functions you create, allowing you to make improvements without breaking backwards compatibility. The most similar config system we're aware of is Gin, which uses a similar syntax, and also allows you to link the configuration system to functions in your code using a decorator. confection's config system is simpler and emphasizes a different workflow via a subset of Gin's functionality. --- devel/Makefile | 1 + devel/py-confection/Makefile | 24 ++++++++++++++++++++++++ devel/py-confection/distinfo | 3 +++ devel/py-confection/pkg-descr | 20 ++++++++++++++++++++ 4 files changed, 48 insertions(+) diff --git a/devel/Makefile b/devel/Makefile index 645d50f5bb51..63bf5921c4d2 100644 --- a/devel/Makefile +++ b/devel/Makefile @@ -4520,6 +4520,7 @@ SUBDIR += py-comm SUBDIR += py-commandlines SUBDIR += py-conditional + SUBDIR += py-confection SUBDIR += py-configargparse SUBDIR += py-configobj SUBDIR += py-configparser diff --git a/devel/py-confection/Makefile b/devel/py-confection/Makefile new file mode 100644 index 000000000000..898256be02cb --- /dev/null +++ b/devel/py-confection/Makefile @@ -0,0 +1,24 @@ +PORTNAME= confection +PORTVERSION= 0.1.4 +CATEGORIES= devel python +MASTER_SITES= PYPI +PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} + +MAINTAINER= sunpoet@FreeBSD.org +COMMENT= Sweetest config system for Python +WWW= https://github.com/explosion/confection + +LICENSE= MIT +LICENSE_FILE= ${WRKSRC}/LICENSE + +BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}setuptools>=0:devel/py-setuptools@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}wheel>=0:devel/py-wheel@${PY_FLAVOR} +RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pydantic2>=1.7.4<3.0.0:devel/py-pydantic2@${PY_FLAVOR} \ + ${PYTHON_PKGNAMEPREFIX}srsly>=2.4.0<3.0.0:devel/py-srsly@${PY_FLAVOR} + +USES= python +USE_PYTHON= autoplist concurrent pep517 + +NO_ARCH= yes + +.include diff --git a/devel/py-confection/distinfo b/devel/py-confection/distinfo new file mode 100644 index 000000000000..9eb5e705dd7c --- /dev/null +++ b/devel/py-confection/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1708448816 +SHA256 (confection-0.1.4.tar.gz) = e80f22fd008b5231a2e8852fac6de9e28f2276a04031d0536cff74fe4a990c8f +SIZE (confection-0.1.4.tar.gz) = 38679 diff --git a/devel/py-confection/pkg-descr b/devel/py-confection/pkg-descr new file mode 100644 index 000000000000..5d85e5172784 --- /dev/null +++ b/devel/py-confection/pkg-descr @@ -0,0 +1,20 @@ +confection is a lightweight library that offers a configuration system letting +you conveniently describe arbitrary trees of objects. + +Configuration is a huge challenge for machine-learning code because you may want +to expose almost any detail of any function as a hyperparameter. The setting you +want to expose might be arbitrarily far down in your call stack, so it might +need to pass all the way through the CLI or REST API, through any number of +intermediate functions, affecting the interface of everything along the way. And +then once those settings are added, they become hard to remove later. Default +values also become hard to change without breaking backwards compatibility. + +To solve this problem, confection offers a config system that lets you easily +describe arbitrary trees of objects. The objects can be created via function +calls you register using a simple decorator syntax. You can even version the +functions you create, allowing you to make improvements without breaking +backwards compatibility. The most similar config system we're aware of is Gin, +which uses a similar syntax, and also allows you to link the configuration +system to functions in your code using a decorator. confection's config system +is simpler and emphasizes a different workflow via a subset of Gin's +functionality.