     nil))
 
 (defun fsharp-ac-can-make-request ()
-  (and fsharp-ac-completion-process
+  (and (fsharp-ac--process-live-p)
        (or
         (member (expand-file-name (buffer-file-name)) fsharp-ac-project-files)
-        (string-match-p (rx (or "fs" "fsx" "fsscript"))
+        (string-match-p (rx (or "fsx" "fsscript"))
                         (file-name-extension (buffer-file-name))))))
 
 (defvar fsharp-ac-awaiting-tooltip nil)


(defun fsharp-ac/load-file (file)
  "Start the compiler binding for an individual F# script."
  (when (and file (equal "fsx" (file-name-extension file)))
    (fsharp-ac--reset)
    (if (file-exists-p file)
        (fsharp-ac-start-process)
      (add-hook 'after-save-hook 'fsharp-ac--load-after-save nil 'local))))

(defun fsharp-ac--load-after-save ()

  (and file
       (file-exists-p file)
       (string-match-p (rx "." (or "fsproj" "sln") eol) file)))

(defun fsharp-ac--script-file-p (file)
  (and file
       (string-match-p (rx (or "fsx" "fsscript"))
                       (file-name-extension file))))

(defun fsharp-ac--reset ()
  (setq fsharp-ac-completion-cache nil
