8000 added ipython.__bibtex__ attribute by Tafkas · Pull Request #6755 · ipython/ipython · GitHub
[go: up one dir, main page]

Skip to content

added ipython.__bibtex__ attribute #6755

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed

added ipython.__bibtex__ attribute #6755

wants to merge 1 commit into from

Conversation

Tafkas
Copy link
@Tafkas Tafkas commented Oct 21, 2014

Added a bibtex attribute for quick command-line access to the recommended citation info. Idea by @jakevdp: https://twitter.com/jakevdp/status/524329573580697600

@Carreau
Copy link
Member
Carreau commented Oct 21, 2014

I think we should think a bit more if we want that, or an tuple of citation, especially for big projects with many article. Also I'm not sure if the dunder is necessary.

I also think that the data of the __bibtex__ shoudl be a method, and that the data should be store in a more structured format.

We should probably discuss of a format before jumping into this.

@Tafkas
Copy link
Author
Tafkas commented Oct 21, 2014

I like the idea. So far I just found this info: http://ipython.org/citing.html

@Carreau
Copy link
Member
Carreau commented Oct 21, 2014

Yes, but if ever we add things we need (at least) a list. And we should absolutely be coherent across packages. I saw that you opened similar PR on other packages. If we do that across scipy, we shoudl absolutely have the same structure everywhere, which require a bit of thinking about :

1 - is it a attribute or a function ? (function give os more flexibility, not sure if you can do properties module wide), and does it takes params ?
2 - Which format ? List, tuple, dict...

Bibtex is nice, but hard to parse, should we have a pybtex data embeded that can be converted to non-bitex, and to bibtex ?

@Carreau
Copy link
Member
Carreau commented Oct 21, 2014

Note, that I have seen the subject on Julia IIRC, where they wonder wether you like this even on a per-function basis, to know that a specific function implement an algorithm for a particular paper. I can see lots of project needing that too.

@dsblank
Copy link
Contributor
dsblank commented Oct 21, 2014

This is a great idea! But does require some discussion.

  • Needs to work for variety of objects
  • Should be language-agnostic
  • How will these be discovered? Iterating through all objects?

This would be a great topic for discussion for a board of advisors for Scientific Computing... not to get bogged down in a "standards process" but for a group of people to quickly, efficiently make recommendations for broad use and adoption.

I do think that Bibtex is the right format to choose, but maybe there should be a way for these to register themselves. Use case:

  • use a bunch of code, libraries
  • Ok, now I want to cite what I have used
  • "Code, please tell me the citations to all of the ideas that I am using." Response: list of citations.

@Carreau
Copy link
Member
Carreau commented Oct 21, 2014

Lets not jump to far forward, and think at module level.

Also here are the 3 other issues linked to that :

scikit-learn/scikit-learn#3789
networkx/networkx#1271
matplotlib/matplotlib#3688

IMHO if should be stored as something more friendly and robust (eg, json), and __bibtex__ should be a function that returns the bibtex string.

@Carreau
Copy link
Member
Carreau commented Oct 21, 2014

i did cross post the following in the 3 other issues to try to regroup the discussion:

Cross posted from #6755 , I don't think it should be a string, but a tuple of string, (cf discussion there) and a method, not attribute (to be able to do some dynamic fetching like in submodules and equivalent. If we do that, it should really be uniform among scipy packages.

Also let's find a unique place to discuss that.

@Carreau
Copy link
Member
Carreau commented Oct 21, 2014

@jakevdp already did that on astroML : astroML/astroML@57fba48

@juhasch
Copy link
juhasch commented Oct 21, 2014

I don't believe Bibtex would be the ideal format. It is from a pre-Internet age, so specifying links or other online resources is always kind of akward. Also, there is more than scientific literature. Technical reports often are referenced very differently (i.e. the author might be irrelevant).

So I would pledge for a more flexible format, and as @Carreau suggested, an easier to parse one.

@dsblank
Copy link
Contributor
dsblank commented Oct 21, 2014

Perhaps a citation could be in any one of a number of styles. That would suggest using __cite__ and allow Bibtex to be one of the styles that the citation format is in.

JSON doesn't help all that much for Bibtex. For example, the title value could be "This is the title", or "{T}his is the {T}itle"... it will still need to be parsed.

Perhaps Bibtex-string or Bibtex-JSON are possible formats.

@tacaswell
Copy link
Contributor

I am deeply skeptical of any format for citations which is not bibtex. It is a stable, well understood, non-proprietary, pure-text format. It has entry types for tech reports as will as articles, books, etc. It should also be injestable by any citation manager worth it's salt (yes, no true Scottsman but come on).

At least the APS styles do a decent job of formatting links/eprints.

@juhasch
Copy link
juhasch commented Oct 21, 2014

I don't think the suggestion is to reinvent the bib format. It is no doubt a good format for scientific citations. I use it regularly. That said, it is not such a good format for internet and non-scientific resources citations.

If some of the projects with the highest visibility in the scientific/engineering Python community implement a citation standard that is based on bibtex only, others will follow.

I believe we should allow different formats. Say e.g. __citation__['bibtex'] = ... and add a bibtex format citation, but do not enforce it to be the only format.

@takluyver
Copy link
Member

There is a json format for citations which at least zotero can export, and
is the native format for citeproc-js. I am looking into this for a citation
extension in the live notebook (more soon). This seems a better option to
me than storing bibtex in a string.

@dsblank
Copy link
Contributor
dsblank commented Oct 21, 2014

@Carreau I would also think that a language kernel would have citation information too.

Another way to go about all of this might be to have a centralized repository (such as a github repo) of associated project names to citation entries. Combined with some server-side code, one could then get citation data for a named project (library, language kernel, etc).

@Carreau
Copy link
Member
Carreau commented Nov 18, 2014

I'm going to close as every project is basically waiting for other project to decide what to do.

Feel free to start a discussion on what format how should be done in a central place and reopen later if there is a concensus.

Thanks !

@Carreau Carreau closed this Nov 18, 2014
@dsblank
Copy link
Contributor
dsblank commented Jan 25, 2015

Just putting a reference to code DOI here:

https://guides.github.com/activities/citable-code/

@minrk minrk modified the milestone: no action Jan 29, 2015
@tacaswell
Copy link
Contributor

matplotlib/matplotlib#6204

mpl has (finally) merged our version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants
0