djangonic way to deal with rdf?

前端 未结 2 1620
温柔的废话
温柔的废话 2021-02-15 13:54

I was looking for an RDF project for django and I cant find any active.

This seems to be a good one http://code.google.com/p/django-rdf, but the last commit was in 2008,

相关标签:
2条回答
  • 2021-02-15 14:38

    http://code.google.com/p/djubby/

    SURF is useful as a RDF->object mapper (or RDFAlchemy)

    injecting rdfa into your templates should work either (if you want to avoid triplestores)

    you can also expose your database as a sparql endpoint using a tool such as http://d2rq.org/

    0 讨论(0)
  • 2021-02-15 14:41

    From what little I've read of RDF you are probably going to have to do manual work to get meaningful RDF statements from Django models since it's not a simple data representation format like JSON, it is trying to encode semantic meaning.

    That said, have a look at django-rdflib:
    https://github.com/odeoncg/django-rdflib

    There doesn't seem to be any documentation (and it seems to have been built for a specific app) but the author has posted here about a manage.py syncvb command that generates an RDF graph from existing Django models:
    https://groups.google.com/d/msg/django-rdf/14WVK7t88PE/ktAKJo-aCfUJ

    Not sure exactly what views django-rdflib provides, but if it can make an RDFlib graph for you then you can probably use the serialization plugins provided by RDFlib to output rdf+xml or whatever from your own view.

    0 讨论(0)
提交回复
热议问题