citeproc-php

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

citeproc-php

Jerome, Ron
FYI, all this talk of development has prompted me to put my somewhat incomplete citeproc-php out there...

http://bitbucket.org/rjerome/citeproc-php

The next version of my Biblio module for Drupal will use similar code for citation formatting.


Ron.
------------------------------------------------------------------------------

_______________________________________________
xbiblio-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/xbiblio-devel
Reply | Threaded
Open this post in threaded view
|

Re: citeproc-php

Bruce D'Arcus-3
On Wed, May 26, 2010 at 10:18 PM, Jerome, Ron <[hidden email]> wrote:
> FYI, all this talk of development has prompted me to put my somewhat incomplete citeproc-php out there...
>
> http://bitbucket.org/rjerome/citeproc-php
>
> The next version of my Biblio module for Drupal will use similar code for citation formatting.

Nice; great to see!

Bruce

------------------------------------------------------------------------------

_______________________________________________
xbiblio-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/xbiblio-devel
Reply | Threaded
Open this post in threaded view
|

Re: citeproc-php

panyasan
Administrator
This post was updated on .
In reply to this post by Jerome, Ron
Very cool, thanks! Having no time to do this myself, I have been waiting for a PHP implementation literally for years. I have experimented with creating a bridge between citeproc-hs and PHP:

https://xbiblio.svn.sourceforge.net/svnroot/xbiblio/citeproc-hs-php/

which, however, had a daunting list of dependencies if you're not a haskell person (even though from what I gather on the list, installation of citeproc-hs with bibutils support etc has gotten easier). To be sure, it would be interesting to compare performance especially on really large bibliographies, and the pandoc support that citeproc-hs offers is very powerful.

Are you planning to support the test suite that Frank has been maintaining so commendably?

Thanks,

Christian
Reply | Threaded
Open this post in threaded view
|

Re: citeproc-php

panyasan
Administrator
While we're at it: is there any interest at all in the "haskell/cabal-for-dummies" citeproc-hs installation script, which is meanwhile probably totally outdated:

https://xbiblio.svn.sourceforge.net/svnroot/xbiblio/citeproc-hs-php/trunk/bin/install.sh

or am I the only one who needed something like that? Because if yes, I would like to ask Andrea if he could have a look and tell me what can be thrown out or needs to be updated.

BTW, I think it would be good to update the page

http://citationstyles.org/citation-style-language/csl-processors/

with some more detailed information what the state of development of the implementations is (in particular, how complete their support of the spec is. I couldn't open the page http://code.haskell.org/citeproc-hs/ but that might just be my connection here.

Thanks,
Christian

Reply | Threaded
Open this post in threaded view
|

Re: citeproc-php

Andrea Rossato
On Thu, May 27, 2010 at 12:48:40AM -0700, panyasan wrote:

>
> While we're at it: is there any interest at all in the
> "haskell/cabal-for-dummies" citeproc-hs installation script, which is
> meanwhile probably totally outdated:
>
> https://xbiblio.svn.sourceforge.net/svnroot/xbiblio/citeproc-hs-php/trunk/bin/install.sh
>
> or am I the only one who needed something like that? Because if yes, I would
> like to ask Andrea if he could have a look and tell me what can be thrown
> out or needs to be updated.

I'm addressing the dependency problem and I think I was able to remove
the most difficult ones:

 - HXT has gone: by default citeproc-hs only needs xml, a very simple
   xml library;

 - hs-bibutils does not require installing bibutils any longer and
   should be easily installed with "cabal install" (this will be a
   dependency activated by default in the next citeproc-hs release).

 - I added the JSON dependency. Moreover something to retrieve styles
   from on-line repositories will be needed, but I plan not to extend
   the pandoc dependencies

While I did not do any test citeproc-hs should be easily installable
with the Haskell platform installed and a simple "cabal install"
command.

In other words, I hope to make your script obsolete and greatly
simplify the installation process with the next release.

I also have an idea... I could write C bindings to citeproc-hs (it
should not be that difficult, actually: Haskell foreign function
interface is very easy and powerful). This way, writing PHP bindings
to the C bindings could be trivial (BTW, this is not science-fiction:
someone was distributing C bindings to pandoc...).

> I couldn't open the page http://code.haskell.org/citeproc-hs/ but that
> might just be my connection here.

That should just be a momentary problem (haskell.org connectivity is
donated ... and sometime you need to be patient).

Andrea

------------------------------------------------------------------------------

_______________________________________________
xbiblio-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/xbiblio-devel
Reply | Threaded
Open this post in threaded view
|

Re: citeproc-php

panyasan
Administrator
Andrea Rossato wrote
In other words, I hope to make your script obsolete and greatly
simplify the installation process with the next release.
That would be so wonderful! I'd really appreciate.

Andrea Rossato wrote
I also have an idea... I could write C bindings to citeproc-hs (it
should not be that difficult, actually: Haskell foreign function
interface is very easy and powerful). This way, writing PHP bindings
to the C bindings could be trivial (BTW, this is not science-fiction:
someone was distributing C bindings to pandoc...).
This would be even better! Unfortunately, however, I couldn't be of help here because I am not a C programmer and could not create the PHP extension that would be necessary. I am sure, though, that this would be very popular and would extend the citeproc-hs user base considerably. One could also think of writing bindings to python, then.

Thanks,
Christian
Reply | Threaded
Open this post in threaded view
|

Re: citeproc-php

fbennett
In reply to this post by panyasan
On Thu, May 27, 2010 at 4:35 PM, panyasan <[hidden email]> wrote:

>
> Very cool, thanks! Having no time doing this myself, I have been waiting for
> a PHP implementation literally for years. I have experimented with creating
> a bridge between citeproc-hs and PHP:
>
> https://xbiblio.svn.sourceforge.net/svnroot/xbiblio/citeproc-hs-php/
>
> which, however, had a daunting list of dependencies if you're not a haskell
> person (even though from what I gather on the list, installation of
> citeproc-hs with bibutils support etc has gotten easier). To be sure, it
> would be interesting to compare performance especially on really large
> bibliographies, and the pandoc support that citeproc-hs offers is very
> powerful.

For performance tests with citeproc-js, the JS engine used will make a
lot of difference.  So far, the code has been run in the test bed
under Rhino, Spidermonkey and Tracemonkey, with Rhino the slowest
performer, Tracemonkey the fastests, and Spidermonkey somewhere in
between.  In-browser the code has been run on webkit and v8 as well,
with v8 apparently the fastest of the lot.

It's just a guess, but the fastest run times for citeproc-js would
probably come from running it under nodejs, with libxmljs for XML
parsing.  Setting that up is beyond my ken, but with the xmldom.js
module now available in citeproc-js, presumably someone will
eventually get around to doing it.

Would be very interesting to see what the performance gap between
citeproc-js and citeproc-hs looks like with very large data sets.




>
> Are you planning to support the test suite that Frank has been maintaining
> so commendably?
>
> Thanks,
>
> Christian
>
> --
> View this message in context: http://xbiblio-devel.2463403.n2.nabble.com/citeproc-php-tp5106642p5107357.html
> Sent from the xbiblio-devel mailing list archive at Nabble.com.
>
> ------------------------------------------------------------------------------
>
> _______________________________________________
> xbiblio-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/xbiblio-devel
>

------------------------------------------------------------------------------

_______________________________________________
xbiblio-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/xbiblio-devel
Reply | Threaded
Open this post in threaded view
|

Re: citeproc-php

panyasan
Administrator
Frank Bennett-3 wrote
Would be very interesting to see what the performance gap between
citeproc-js and citeproc-hs looks like with very large data sets.
Yes, it will be nice once we have a set of alternative, easy-to-install server-side citeproc implementations that we can compare with each other. The key point, for me, is the "easy-to-install". The more dependencies are involved, the more deterring it is for people to use. For example, seen from PHP, having to install a Java VM to run a javascript program, which then has to be called through the command line is a huge problem. node.js is a step in the right direction, but, from scripting languages such as PHP and Python you will prefer to call C executables or libraries if you don't have a fast native implementation...

It is certainly great to see things move forward on the server side! Thanks for all the work involved.

Christian
Reply | Threaded
Open this post in threaded view
|

Re: citeproc-php

Jerome, Ron
In reply to this post by panyasan

>Very cool, thanks! Having no time doing this myself, I have been waiting for
>a PHP implementation literally for years. I have experimented with creating
>a bridge between citeproc-hs and PHP:

Your welcome, I had been waiting also, but finaly decided to roll up my sleaves and dig in.

>Are you planning to support the test suite that Frank has been maintaining
>so commendably?

Yes, it works with Franks tests and I will upload a test suite shortly.  I had another inquiry regarding citeproc-php, so I wanted to (at least) get the base code out in the wild.

Ron.
------------------------------------------------------------------------------

_______________________________________________
xbiblio-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/xbiblio-devel