mirror of
				https://github.com/explosion/spaCy.git
				synced 2025-11-04 01:48:04 +03:00 
			
		
		
		
	Merge remote-tracking branch 'upstream/master' into web-doc-patches
This commit is contained in:
		
						commit
						a78062e466
					
				| 
						 | 
				
			
			@ -38,9 +38,10 @@ p
 | 
			
		|||
    |  #[code spacy/data] directory. This means your user needs permission to do
 | 
			
		||||
    |  this. The above error mostly occurs when doing a system-wide installation,
 | 
			
		||||
    |  which will create the symlinks in a system directory. Run the
 | 
			
		||||
    |  #[code download] or #[code link] command as administrator, or use a
 | 
			
		||||
    |  #[code virtualenv] to install spaCy in a user directory, instead
 | 
			
		||||
    |  of doing a system-wide installation.
 | 
			
		||||
    |  #[code download] or #[code link] command as administrator (on Windows,
 | 
			
		||||
    |  simply right-click on your terminal or shell ans select "Run as
 | 
			
		||||
    |  Administrator"), or use a #[code virtualenv] to install spaCy in a user
 | 
			
		||||
    |  directory, instead of doing a system-wide installation.
 | 
			
		||||
 | 
			
		||||
+h(3, "no-cache-dir") No such option: --no-cache-dir
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -91,6 +91,10 @@ p
 | 
			
		|||
        +cell.u-nowrap #[code LOWER]
 | 
			
		||||
        +cell The lowercase form of the token text.
 | 
			
		||||
 | 
			
		||||
    +row
 | 
			
		||||
        +cell #[code LENGTH]
 | 
			
		||||
        +cell The length of the token text.
 | 
			
		||||
 | 
			
		||||
    +row
 | 
			
		||||
        +cell.u-nowrap #[code IS_ALPHA], #[code IS_ASCII], #[code IS_DIGIT]
 | 
			
		||||
        +cell
 | 
			
		||||
| 
						 | 
				
			
			@ -335,7 +339,8 @@ p
 | 
			
		|||
    |  flag.
 | 
			
		||||
 | 
			
		||||
+code.
 | 
			
		||||
    IS_DEFINITELY = nlp.vocab.add_flag(re.compile(r'deff?in[ia]tely').match)
 | 
			
		||||
    definitely_flag = lambda text: bool(re.compile(r'deff?in[ia]tely').match(text))
 | 
			
		||||
    IS_DEFINITELY = nlp.vocab.add_flag(definitely_flag)
 | 
			
		||||
 | 
			
		||||
    matcher = Matcher(nlp.vocab)
 | 
			
		||||
    matcher.add('DEFINITELY', None, [{IS_DEFINITELY: True}])
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -31,3 +31,13 @@ p
 | 
			
		|||
    import spacy
 | 
			
		||||
    nlp = spacy.load('en')
 | 
			
		||||
    doc = nlp(u'This is a sentence.')
 | 
			
		||||
 | 
			
		||||
+infobox("Important note", "⚠️")
 | 
			
		||||
    |  To allow loading models via convenient shortcuts like #[code 'en'], spaCy
 | 
			
		||||
    |  will create a symlink within the #[code spacy/data] directory. This means
 | 
			
		||||
    |  that your user needs the #[strong required permissions].
 | 
			
		||||
    |  If you've installed spaCy to a system directory and don't have admin
 | 
			
		||||
    |  privileges, the model linking may fail. The easiest solution
 | 
			
		||||
    |  is to re-run the command as admin, or use a #[code virtualenv]. For more
 | 
			
		||||
    |  info on this, see the
 | 
			
		||||
    |  #[+a("/usage/#symlink-privilege") troubleshooting guide].
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -132,7 +132,7 @@ p
 | 
			
		|||
    # set up shortcut link to load local model as "my_amazing_model"
 | 
			
		||||
    python -m spacy link /Users/you/model my_amazing_model
 | 
			
		||||
 | 
			
		||||
+infobox("Important note")
 | 
			
		||||
+infobox("Important note", "⚠️")
 | 
			
		||||
    |  In order to create a symlink, your user needs the #[strong required permissions].
 | 
			
		||||
    |  If you've installed spaCy to a system directory and don't have admin
 | 
			
		||||
    |  privileges, the #[code spacy link] command may fail. The easiest solution
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue
	
	Block a user