jtauber / greek-accentuation

Python 3 library for accenting (and analyzing the accentuation of) Ancient Greek words
MIT License
54 stars 10 forks source link

consider containing package #2

Closed jtauber closed 8 years ago

jtauber commented 8 years ago

I've often regretted that the three modules in greek-accentuation don't have a containing package.

What should it be called though? greek_accentuation?

This would mean

Any other name suggestions? The second seems a little awkward.

Might be a good final step before declaring 1.0.0 😄

kylepjohnson commented 8 years ago

Hi James, I think that's a fine name. I like to import my models in the following way. Is this along the lines of what you were thinking about?

>>> from greek_accentuation import characters
>>> from greek_accentuation import syllabify
>>> from greek_accentuation import accentuation

Your project is definitely due for a 1.0 release! I am also thinking about including it by default into the cltk (I don't know if that changes anything for you). @j-duff can chime in, too.

jtauber commented 8 years ago

Yes, you could do

from greek_accentuation import characters

or things like

from greek_accentuation.characters import strip_accents

The other thing I could do if there are no name clashes across the three modules is have greek_accentuation/__init__.py import the modules so things like from greek_accentuation import strip_accents would work.

I'll also take the opportunity to move over some (but not all) of the stuff in https://github.com/jtauber/greek-inflexion/blob/master/accent.py to this package.

kylepjohnson commented 8 years ago

Sounds perfect.

The other thing I could do if there are no name clashes across the three modules is have

I personally disfavor these, as it complicates debugging. However there are times it's called for, I'm sure.

jtauber commented 8 years ago

Done (minus any magic in __init__.py) and released as 1.0.0

jtauber commented 8 years ago

@kylepjohnson I'd be delighted for it to be included in CLTK by default.

kylepjohnson commented 8 years ago

:tada:

Let's add it when we push Jack's work!

My request for you is to think about what kind of info we should include in the cltk docs. We should do more than just a link to your site, however we don't need to explain every nuance, either. Let us know (maybe Jack can help) or make a PR yourself.

jtauber commented 8 years ago

Yeah, there are a lot of "internal" functions that aren't likely to be useful to most people. I'll think about some key functions that form the "core API" and write up some docs on those which I'll include in this repo but which you can re-use in CLTK.