Giter VIP home page Giter VIP logo

Comments (5)

kzk2000 avatar kzk2000 commented on June 25, 2024 1

[...] that match tags with simple =, in, not =, not in type operations.

this was exactly where I was going with this, works for me!

from hamilton.

elijahbenizzy avatar elijahbenizzy commented on June 25, 2024

Agreed that we should allow for some structure here. I think we have two choices:

  1. Allow any arbitrary json here
  2. Allow some specific structure that has semantic meaning.

I'm going to recommend (2). In this case:

  • strings assign a value to the tag
  • lists assign multiple values to the tag

Then we have a query system (suggested in here) that allows you to query for nodes that match tags. With simple =, in, not =, not in type operations. The driver maintains a list and can do the queries for you. I don't really foresee the need for anything more complex than these operations, which work nicely with the list suggested here and match the common configuration patterns... @config.when, @config.when_in, etc...

from hamilton.

skrawcz avatar skrawcz commented on June 25, 2024

also - #293.

from hamilton.

skrawcz avatar skrawcz commented on June 25, 2024

Otherwise I think lists of strings seem to be fine. Can't seem to recall why we didn't do this in the first place.

The other -- nested dicts can already be done with the namespacing/dot stuff.

@tag(**{'my.tag': 'tag_value'})
       def my_function(...) -> ...:

from hamilton.

skrawcz avatar skrawcz commented on June 25, 2024

@kzk2000 want to take #622 for a spin?

You should be able to do what you asked for.

from hamilton.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.